Skip to content

parallelcc/FFmpeg-WHIP-WHEP

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

FFmpeg-WHIP-WHEP

This is a fork of the FFmpeg project that adds support for the WHIP (WebRTC-HTTP ingestion protocol) and WHEP (WebRTC-HTTP Egress Protocol) using libdatachannel.

Supported Codecs

WHIP

Default: H264 / OPUS

  • Video: H264 / H265
  • Audio: OPUS / PCMA / PCMU / G722

WHEP

  • Video: H264 / H265 / VP8 / VP9
  • Audio: OPUS / PCMA / PCMU / G722

Usage

WHIP

Docker

docker run --rm -it -v $(pwd):/app \
    parallelcc/ffmpeg-whip-whep:7.1.1 \
    -re -i /app/input.mp4 -f whip -token <token> <whip_url>

Local build

ffmpeg -re -i input.mp4 -f whip -token <token> <whip_url>

WHEP

Docker

docker run --rm -it -v $(pwd):/app \
    parallelcc/ffmpeg-whip-whep:7.1.1 \
    -f whep -token <token> -i <whep_url> \
    -c:v libx264 -c:a aac /app/output.mp4

Local build

# play
ffplay -f whep -token <token> <whep_url>

# record
ffmpeg -f whep -token <token> -i <whep_url> \
    -c:v libx264 -c:a aac output.mp4

Building

  1. Build libdatachannel by following the instructions in its BUILDING.md.

  2. Install libdatachannel to the system directory using make install.

  3. Clone this repository and build it following the FFmpeg Compilation Guide. Be sure to add --enable-libdatachannel when running the ./configure script.

FFmpeg README

FFmpeg is a collection of libraries and tools to process multimedia content such as audio, video, subtitles and related metadata.

Libraries

  • libavcodec provides implementation of a wider range of codecs.
  • libavformat implements streaming protocols, container formats and basic I/O access.
  • libavutil includes hashers, decompressors and miscellaneous utility functions.
  • libavfilter provides means to alter decoded audio and video through a directed graph of connected filters.
  • libavdevice provides an abstraction to access capture and playback devices.
  • libswresample implements audio mixing and resampling routines.
  • libswscale implements color conversion and scaling routines.

Tools

  • ffmpeg is a command line toolbox to manipulate, convert and stream multimedia content.
  • ffplay is a minimalistic multimedia player.
  • ffprobe is a simple analysis tool to inspect multimedia content.
  • Additional small tools such as aviocat, ismindex and qt-faststart.

Documentation

The offline documentation is available in the doc/ directory.

The online documentation is available in the main website and in the wiki.

Examples

Coding examples are available in the doc/examples directory.

License

FFmpeg codebase is mainly LGPL-licensed with optional components licensed under GPL. Please refer to the LICENSE file for detailed information.

Contributing

Patches should be submitted to the ffmpeg-devel mailing list using git format-patch or git send-email. Github pull requests should be avoided because they are not part of our review process and will be ignored.

About

Enable WHIP/WHEP support in FFmpeg using libdatachannel

Topics

Resources

License

Unknown and 3 other licenses found

Licenses found

Unknown
LICENSE.md
GPL-2.0
COPYING.GPLv2
GPL-3.0
COPYING.GPLv3
LGPL-3.0
COPYING.LGPLv3

Stars

Watchers

Forks

Sponsor this project

 

Packages

No packages published

Contributors 1,399