diff --git a/README.md b/README.md index af551a8f..6fe19a1a 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,20 @@ It is a part of [Membrane Multimedia Framework](https://membraneframework.org). ## Installation +First, you need to install FFmpeg on your system: + +### macOS + +```shell +brew install ffmpeg +``` + +### Ubuntu + +```shell +sudo apt-get install ffmpeg +``` + The package can be installed by adding `membrane_rtmp_plugin` to your list of dependencies in `mix.exs`: ```elixir @@ -20,23 +34,29 @@ end ``` ## SourceBin + Requires a socket, which has been connected to the client. It receives RTMP stream, demuxes it and outputs H264 video and AAC audio. ## Client + After establishing connection with server it waits to receive video and audio streams. Once both streams are received they are streamed to the server. Currently only the following codecs are supported: + - H264 for video - AAC for audio ## TCP Server + It's a simple implementation of tcp server. It opens a tcp port and listens for incoming connections. For each new connection, a user-provided function is executed. ### Prerequisites + In order to successfully build and install the plugin, you need to have **ffmpeg == 4.4** installed on your system ## Usage ### RTMP receiver + Server-side example, in which Membrane will act as an RTMP server and receive the stream, can be found under [`examples/source.exs`](examples/source.exs). Run it with: ```bash @@ -50,6 +70,7 @@ ffmpeg -re -i test/fixtures/testsrc.flv -f flv -c:v copy -c:a copy rtmp://localh ``` ### Streaming with RTMP + Streaming implementation example is provided with the following [`examples/sink.exs`](examples/sink.exs). Run it with: ```bash