#[non_exhaustive]pub enum Container {
Mp4,
FMp4,
WebM,
Mkv,
Avi,
Mov,
Flac,
Ogg,
}Expand description
Container format for output file.
The container format is usually auto-detected from the file extension, but can be explicitly specified if needed.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Mp4
MP4 / QuickTime
FMp4
Fragmented MP4 — CMAF-compatible streaming container.
Uses the same mp4 FFmpeg muxer as Container::Mp4 but with
movflags=+frag_keyframe+empty_moov+default_base_moof applied before
writing the header. Required for HTTP Live Streaming fMP4 segments
(CMAF) and MPEG-DASH.
WebM
WebM
Mkv
Matroska
Avi
AVI
Mov
MOV
Flac
FLAC (lossless audio container)
Ogg
OGG (audio container for Vorbis/Opus)
Implementations§
Source§impl Container
impl Container
Sourcepub const fn default_extension(self) -> &'static str
pub const fn default_extension(self) -> &'static str
Get default file extension.
Sourcepub const fn is_fragmented(self) -> bool
pub const fn is_fragmented(self) -> bool
Returns true if this container is fragmented MP4.
When true, the encoder applies
movflags=+frag_keyframe+empty_moov+default_base_moof before writing
the file header, enabling CMAF-compatible streaming output.
Trait Implementations§
impl Copy for Container
impl Eq for Container
impl StructuralPartialEq for Container
Auto Trait Implementations§
impl Freeze for Container
impl RefUnwindSafe for Container
impl Send for Container
impl Sync for Container
impl Unpin for Container
impl UnsafeUnpin for Container
impl UnwindSafe for Container
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more