ffmpeg-pipeline
ffmpeg-pipeline provides composable Rust APIs for common media-processing workflows on top of ffmpeg-next. It operates directly through FFmpeg libraries and never invokes the ffmpeg command-line program.
Features
- Decode audio and video streams as packets or frames.
- Encode audio and video with configurable codec parameters and metadata.
- Resample, reformat, and buffer audio for encoder frame requirements.
- Scale decoded video frames.
- Remux selected streams while preserving or replacing stream metadata.
- Read from files, byte buffers, or custom
Read + Seeksources. - Write to files, byte buffers, or custom
Write + Seekdestinations. - Inspect stream metadata and calculate video frame counts.
Installation
[]
= "0.1"
= "0.4"
The crate links FFmpeg statically. Provide a compatible FFmpeg 7.1 installation through FFMPEG_DIR, or enable source compilation:
[]
= { = "0.1", = ["build-from-source"] }
The available codecs and formats are determined by the linked FFmpeg build. Platform system libraries and frameworks may still be required; third-party FFmpeg dependencies must be linked statically.
Example
use ;
Call initialize once before creating FFmpeg contexts. See the API documentation for decoding, encoding, remuxing, scaling, and custom I/O types.
Status
The crate is under active development. The public API may change before version 1.0.
License
Copyright © 2023–2026 DarkSky.
Licensed under the GNU Affero General Public License, version 3 only.