Skip to main content

Module encode

Module encode 

Source
Expand description

Video encoder — encode a sequence of frames into a video file.

This module provides VideoEncoder for encoding DynamicImage frames into a video container (MP4, MKV, AVI, etc.) using FFmpeg.

§Example

use unbundle::{FrameRange, MediaFile, UnbundleError, VideoEncoder, VideoEncoderOptions};

let mut unbundler = MediaFile::open("input.mp4")?;
let frames = unbundler.video().frames(FrameRange::Range(0, 10))?;
VideoEncoder::new(VideoEncoderOptions::default())
    .write("output.mp4", &frames)?;

Structs§

VideoEncoder
Encodes a sequence of frames into a video file.
VideoEncoderOptions
Options for the video encoder.

Enums§

VideoCodec
Supported output video codecs.