Skip to content

Commit

Permalink
Update README.md (#64)
Browse files Browse the repository at this point in the history
  • Loading branch information
maciejewskakatarzyna committed Jul 24, 2023
1 parent 2f729d1 commit 7426ea3
Showing 1 changed file with 21 additions and 0 deletions.
21 changes: 21 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand All @@ -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
Expand All @@ -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
Expand Down

0 comments on commit 7426ea3

Please sign in to comment.