https://github.com/membraneframework/membrane_matroska_plugin
Matroska muxer and demuxer
https://github.com/membraneframework/membrane_matroska_plugin
Last synced: 3 months ago
JSON representation
Matroska muxer and demuxer
- Host: GitHub
- URL: https://github.com/membraneframework/membrane_matroska_plugin
- Owner: membraneframework
- License: apache-2.0
- Created: 2021-10-05T12:37:52.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2025-05-27T14:48:51.000Z (about 1 year ago)
- Last Synced: 2025-05-27T15:48:06.919Z (about 1 year ago)
- Language: Elixir
- Homepage: https://membrane.stream
- Size: 35.9 MB
- Stars: 2
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Membrane Matroska Plugin
[](https://hex.pm/packages/membrane_matroska_plugin)
[](https://hexdocs.pm/membrane_matroska_plugin)
[](https://circleci.com/gh/membraneframework/membrane_matroska_plugin)
Membrane plugin for muxing and demuxing files in the [Matroska](https://www.matroska.org/index.html) format.
It is part of [Membrane Multimedia Framework](https://membraneframework.org).
- Both muxer and demuxer support tracks encoded with VP8, VP9, H264 and Opus.
- Opus tracks with more than 2 channels are not supported.
- Demuxing of files containing [laced](https://www.ietf.org/archive/id/draft-ietf-cellar-matroska-08.html#section-12.3) frames is not supported.
- Passing tag values is not supported
## Installation
The package can be installed by adding `membrane_matroska_plugin` to your list of dependencies in `mix.exs`:
```elixir
def deps do
[
{:membrane_matroska_plugin, "~> 0.6.0"}
]
end
```
## Usage
### `Membrane.Matroska.Muxer`
Matroska muxer requires a sink that can handle `Membrane.File.SeekEvent`, e.g. `Membrane.File.Sink`.
For an example of muxing streams to a regular matroska file, refer to [`examples/muxer_h264.exs`](examples/muxer_h264.exs).
To run the example, you can use the following command:
```bash
elixir examples/muxer_h264.exs
```
### `Membrane.Matroska.Demuxer`
For an example of demuxing streams, refer to [`examples/demuxer_h264.exs`](examples/demuxer_h264.exs).
To run the example, use the following command:
```bash
elixir examples/demuxer_h264.exs
```
You can expect `demuxing_output` folder to appear and contain an audio file `2.ogg` and a video file `1.h264`.
## Copyright and License
Copyright 2022, [Software Mansion](https://swmansion.com/?utm_source=git&utm_medium=readme&utm_campaign=membrane_matroska_plugin)
[](https://swmansion.com/?utm_source=git&utm_medium=readme&utm_campaign=membrane_matroska_plugin)
Licensed under the [Apache License, Version 2.0](LICENSE)