pub struct H264SliceHeader {
pub first_mb_in_slice: u32,
pub slice_type: H264SliceType,
pub pic_parameter_set_id: u8,
pub is_idr: bool,
pub frame_num: u32,
pub field_pic_flag: bool,
pub bottom_field_flag: bool,
pub colour_plane_id: Option<u8>,
pub idr_pic_id: Option<u32>,
pub pic_order_cnt_lsb: Option<u32>,
pub delta_pic_order_cnt_bottom: Option<i32>,
pub delta_pic_order_cnt: [Option<i32>; 2],
}Expand description
Parsed H.264 slice header — just the fields the Vulkan Video
decoder + our DPB manager need. See ITU-T H.264 §7.3.3. Full slice
header has ref_pic_list_modification, weighted_prediction tables,
dec_ref_pic_marking, etc., which we don’t consume (the driver
re-derives them from the PPS + StdVideoDecodeH264PictureInfo
flags).
Fields§
§first_mb_in_slice: u32§slice_type: H264SliceType§pic_parameter_set_id: u8§is_idr: boolFrom the NAL header: nal_unit_type == 5 — set by the caller
when it picks the NAL to parse. Affects whether idr_pic_id is
carried.
frame_num: u32§field_pic_flag: boolTrue when the slice encodes a single field of an interlaced
frame (spec: !frame_mbs_only_flag && field_pic_flag). False
for progressive frames or MBAFF pairs.
bottom_field_flag: bool§colour_plane_id: Option<u8>§idr_pic_id: Option<u32>Set when is_idr; otherwise None.
pic_order_cnt_lsb: Option<u32>Set when SPS pic_order_cnt_type == 0.
delta_pic_order_cnt_bottom: Option<i32>§delta_pic_order_cnt: [Option<i32>; 2]Set when SPS pic_order_cnt_type == 1 and
!delta_pic_order_always_zero_flag. [0] always present in
that branch, [1] present only when the PPS carried
bottom_field_pic_order_in_frame_present_flag and we’re in a
frame (not field) slice.
Trait Implementations§
Source§impl Clone for H264SliceHeader
impl Clone for H264SliceHeader
Source§fn clone(&self) -> H264SliceHeader
fn clone(&self) -> H264SliceHeader
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for H264SliceHeader
Source§impl Debug for H264SliceHeader
impl Debug for H264SliceHeader
impl Eq for H264SliceHeader
Source§impl PartialEq for H264SliceHeader
impl PartialEq for H264SliceHeader
Source§fn eq(&self, other: &H264SliceHeader) -> bool
fn eq(&self, other: &H264SliceHeader) -> bool
self and other values to be equal, and is used by ==.