Struct Header

Source
pub struct Header {
Show 34 fields pub profile: Profile, pub bit_depth: BitDepth, pub subsampling_x: bool, pub subsampling_y: bool, pub color_space: ColorSpace, pub color_range: ColorRange, pub show_existing_frame: bool, pub frame_to_show_map_idx: u8, pub frame_type: FrameType, pub show_frame: bool, pub error_resilient_mode: bool, pub width: u32, pub height: u32, pub render_and_frame_size_different: bool, pub render_width: u32, pub render_height: u32, pub intra_only: bool, pub reset_frame_context: u8, pub refresh_frame_flags: u8, pub ref_frame_idx: [u8; 3], pub ref_frame_sign_bias: [u8; 4], pub allow_high_precision_mv: bool, pub interpolation_filter: InterpolationFilter, pub refresh_frame_context: bool, pub frame_parallel_decoding_mode: bool, pub frame_context_idx: u8, pub lf: LoopFilterParams, pub quant: QuantizationParams, pub seg: SegmentationParams, pub tile_cols_log2: u8, pub tile_rows_log2: u8, pub lossless: bool, pub header_size_in_bytes: u16, pub uncompressed_header_size_in_bytes: u16,
}
Expand description

A VP9 frame header.

Fields§

§profile: Profile

A subset of syntax, semantics and algorithms defined in a part.

§bit_depth: BitDepth

The bit depth of the frame.

§subsampling_x: bool

Specifies the chroma subsampling format.

§subsampling_y: bool

Specifies the chroma subsampling format.

§color_space: ColorSpace

Specifies the color space of the stream.

§color_range: ColorRange

Specifies the black level and range of the luma and chroma signals as specified in Rec. ITU-R BT.709-6 and Rec. ITU-R BT.2020-2

§show_existing_frame: bool

Indicates the frame indexed by frame_to_show_map_idx is to be displayed. If unset, indicates that further processing is required.

§frame_to_show_map_idx: u8

Specifies the frame to be displayed. It is only available if show_existing_frame is set.

§frame_type: FrameType

Indicates whether a frame is a key frame.

§show_frame: bool

Whether this frame should be displayed.

§error_resilient_mode: bool

Whether error resilient mode is enabled.

§width: u32

The width of the frame in pixels.

§height: u32

The height of the frame in pixels.

§render_and_frame_size_different: bool

If unset, means that the render width and height are inferred from the frame width and height. If set, means that the render width and height are explicitly coded in the bitstream.

§render_width: u32

The render width of the frame in pixels.

§render_height: u32

The render height of the frame in pixels.

§intra_only: bool

If set, indicates that this frame is an intra-only frame. If unset, indicates that this frame is a inter frame.

§reset_frame_context: u8

Specifies whether the frame context should be reset to default values.

§refresh_frame_flags: u8

Contains a bitmask that specifies which reference frame slots will be updated with the current frame after it is decoded.

§ref_frame_idx: [u8; 3]

Specifies which reference frames are used by inter frames. It is a requirement of bitstream conformance that the selected reference frames match the current frame in bit depth, profile, chroma subsampling, and color space.

§ref_frame_sign_bias: [u8; 4]

Specifies the intended direction of the motion vector in time for each reference frame. A sign bias equal to 0 indicates that the reference frame is a backwards reference; a sign bias equal to 1 indicates that the reference frame is a forwards reference

§allow_high_precision_mv: bool

If unset, specifies that motion vectors are specified to quarter pel precision. If set, specifies that motion vectors are specified to eighth pel precision.

§interpolation_filter: InterpolationFilter

The interpolation filter parameters.

§refresh_frame_context: bool

If set, indicates that the probabilities computed for this frame (after adapting to the observed frequencies if adaption is enabled) should be stored for reference by future frames. If unset, indicates that the probabilities should be discarded at the end of the frame.

§frame_parallel_decoding_mode: bool

Whether parallel decoding mode is enabled.

§frame_context_idx: u8

Indicates the frame context to use.

§lf: LoopFilterParams

The loop filter parameters

§quant: QuantizationParams

The quantization parameters.

§seg: SegmentationParams

The segmentation parameters

§tile_cols_log2: u8

Specifies the base 2 logarithm of the width of each tile (where the width is measured in units of 8x8 blocks). It is a requirement of bitstream conformance that tile_cols_log2 is less than or equal to 6.

§tile_rows_log2: u8

Specifies the base 2 logarithm of the height of each tile (where the height is measured in units of 8x8 blocks).

§lossless: bool

Computed from the syntax elements. If set, indicates that the frame is coded using a special 4x4 transform designed for encoding frames that are bit-identical with the original frames.

§header_size_in_bytes: u16

Indicates the size of the compressed header in bytes.

§uncompressed_header_size_in_bytes: u16

Indicates the size of the uncompressed header in bytes.

Trait Implementations§

Source§

impl Clone for Header

Source§

fn clone(&self) -> Header

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for Header

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for Header

Source§

fn default() -> Header

Returns the “default value” for a type. Read more
Source§

impl PartialEq for Header

Source§

fn eq(&self, other: &Header) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Eq for Header

Source§

impl StructuralPartialEq for Header

Auto Trait Implementations§

§

impl Freeze for Header

§

impl RefUnwindSafe for Header

§

impl Send for Header

§

impl Sync for Header

§

impl Unpin for Header

§

impl UnwindSafe for Header

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.