https://github.com/membraneframework/membrane_overlay_plugin
Filter for applying overlay image or text on top of video
https://github.com/membraneframework/membrane_overlay_plugin
Last synced: about 1 year ago
JSON representation
Filter for applying overlay image or text on top of video
- Host: GitHub
- URL: https://github.com/membraneframework/membrane_overlay_plugin
- Owner: membraneframework
- License: apache-2.0
- Created: 2024-02-20T11:25:03.000Z (over 2 years ago)
- Default Branch: master
- Last Pushed: 2024-04-24T08:50:17.000Z (about 2 years ago)
- Last Synced: 2024-04-24T14:24:50.741Z (about 2 years ago)
- Language: Elixir
- Size: 989 KB
- Stars: 3
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Membrane Overlay Plugin
[](https://hex.pm/packages/membrane_overlay_plugin)
[](https://hexdocs.pm/membrane_overlay_plugin)
[](https://circleci.com/gh/membraneframework/membrane_overlay_plugin)
Filter for applying overlay or text over video. Based on the [Image](https://github.com/elixir-image/image) library.
It's a part of the [Membrane Framework](https://membrane.stream).
## Installation
The package can be installed by adding `membrane_overlay_plugin` to your list of dependencies in `mix.exs`:
```elixir
def deps do
[
{:membrane_overlay_plugin, "~> 0.2.0"}
]
end
```
## Usage
To overlay an image in the top-right corner of an H264 video, use the following spec:
```elixir
child(%Membrane.File.Source{location: "input.h264"})
|> child(Membrane.H264.Parser)
|> child(Membrane.H264.FFmpeg.Decoder)
|> child(%Membrane.OverlayFilter{overlay: "image.png", x: :right, y: :top})
|> child(Membrane.H264.FFmpeg.Encoder)
|> child(%Membrane.File.Sink{location: "output.h264"})
```
See the `example.exs` file for a complete example.
## Copyright and License
Copyright 2024, [Software Mansion](https://swmansion.com/?utm_source=git&utm_medium=readme&utm_campaign=membrane)
[](https://swmansion.com/?utm_source=git&utm_medium=readme&utm_campaign=membrane)
Licensed under the [Apache License, Version 2.0](LICENSE)