Trait EncodedFrame

Source
pub trait EncodedFrame: Frame {
    type Param: AsRef<[u8]>;

    // Required methods
    fn pts(&self) -> i64;
    fn params(&self) -> impl Iterator<Item = &Self::Param>;

    // Provided method
    fn dts(&self) -> u64 { ... }
}

Required Associated Types§

Required Methods§

Source

fn pts(&self) -> i64

Presentation timestamp in microseconds - same as DTS, but with frame presentation offset correction

Source

fn params(&self) -> impl Iterator<Item = &Self::Param>

Iterator by NAL units of the parameters (for h264/h265 - VPS,SPS,PPS)

Provided Methods§

Source

fn dts(&self) -> u64

Decoding timestamp in microseconds (monotonic increasing timestamp starting from 0 (usually) at the first frame)

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§