#[non_exhaustive]pub enum Detail {
#[non_exhaustive] Ts {
stride: u16,
phase: u16,
},
#[non_exhaustive] Isobmff {
major_brand: Option<[u8; 4]>,
boxes_walked: u8,
layout: IsobmffLayout,
},
#[non_exhaustive] Ebml {
doc_type: DocType,
},
#[non_exhaustive] Flv {
has_audio: bool,
has_video: bool,
data_offset: u32,
},
#[non_exhaustive] Mxf {
partition_kind: PartitionKind,
},
#[non_exhaustive] MpegPs {
structurally_valid: bool,
},
None,
}Expand description
What a prober learned on the way to its conclusion — the difference between “it is TS” and “it is TS, 192-byte stride, first sync at offset 4”.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
#[non_exhaustive]Ts
MPEG-2 TS lattice: packet stride (188/192/204/208) and the byte
offset of the first sync (phase), so a demuxer need not re-derive them.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]Isobmff
ISOBMFF: the ftyp major brand (if seen) and how many top-level boxes
chained cleanly.
Fields
This variant is marked as non-exhaustive
layout: IsobmffLayoutWhich structural layout the top-level walk observed — the discriminator between a fragmented and a progressive file.
#[non_exhaustive]Ebml
Matroska/WebM: the EBML header’s DocType string.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]Flv
FLV: the header’s TypeFlags (which tag types are present) and the
DataOffset header size.
Fields
This variant is marked as non-exhaustive
#[non_exhaustive]Mxf
MXF: the decoded Partition Pack kind (byte 14 of the UL).
Fields
This variant is marked as non-exhaustive
partition_kind: PartitionKindWhich Partition Pack this is — see PartitionKind.
#[non_exhaustive]MpegPs
MPEG-PS: whether the pack header’s SCR/mux-rate marker bits validated.
Fields
This variant is marked as non-exhaustive
None
No format-specific detail to report.
Implementations§
Source§impl Detail
impl Detail
Sourcepub fn major_brand_str(&self) -> Option<&str>
pub fn major_brand_str(&self) -> Option<&str>
The ftyp/styp major brand as a string, when the identifying file
carried one (an ISOBMFF result). The brand is a registered 4-character
code, so this is the ergonomic view of the raw [u8; 4] in
Detail::Isobmff.
Returns None when the detail is not Isobmff, when no brand was
observed, or when the 4 bytes are not valid UTF-8.
Trait Implementations§
impl Copy for Detail
Source§impl Display for Detail
A lossless Display for Detail: every data-bearing variant renders its
fields, so Detail::Ts { stride, phase } is not collapsed to just "Ts".
Display delegates to Detail::name (the #204 convention) for the label,
then appends the field data the variant actually carries.
impl Display for Detail
A lossless Display for Detail: every data-bearing variant renders its
fields, so Detail::Ts { stride, phase } is not collapsed to just "Ts".
Display delegates to Detail::name (the #204 convention) for the label,
then appends the field data the variant actually carries.