diff --git a/ash/src/vk.rs b/ash/src/vk.rs index 312741709..3f759aeba 100644 --- a/ash/src/vk.rs +++ b/ash/src/vk.rs @@ -26,7 +26,12 @@ pub use features::*; mod prelude; pub use prelude::*; /// Native bindings from Vulkan headers, generated by bindgen -#[allow(clippy::useless_transmute, nonstandard_style)] +#[allow( + nonstandard_style, + clippy::unnecessary_operation, + clippy::useless_transmute, + clippy::identity_op +)] pub mod native; mod platform_types; pub use platform_types::*; diff --git a/ash/src/vk/native.rs b/ash/src/vk/native.rs index a44e9b7c8..d06164a22 100644 --- a/ash/src/vk/native.rs +++ b/ash/src/vk/native.rs @@ -1,4 +1,4 @@ -/* automatically generated by rust-bindgen 0.69.4 */ +/* automatically generated by rust-bindgen 0.70.0 */ #[repr(C)] #[derive(Copy, Clone, Debug, Default, Eq, Hash, Ord, PartialEq, PartialOrd)] @@ -227,19 +227,11 @@ pub struct StdVideoH264SpsVuiFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>, pub __bindgen_padding_0: u16, } -#[test] -fn bindgen_test_layout_StdVideoH264SpsVuiFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH264SpsVuiFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH264SpsVuiFlags)) - ); -} +const _: () = { + ["Size of StdVideoH264SpsVuiFlags"][::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH264SpsVuiFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoH264SpsVuiFlags { #[inline] pub fn aspect_ratio_info_present_flag(&self) -> u32 { @@ -467,139 +459,41 @@ pub struct StdVideoH264HrdParameters { pub dpb_output_delay_length_minus1: u32, pub time_offset_length: u32, } -#[test] -fn bindgen_test_layout_StdVideoH264HrdParameters() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 308usize, - concat!("Size of: ", stringify!(StdVideoH264HrdParameters)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH264HrdParameters)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cpb_cnt_minus1) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(cpb_cnt_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).bit_rate_scale) as usize - ptr as usize }, - 1usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(bit_rate_scale) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cpb_size_scale) as usize - ptr as usize }, - 2usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(cpb_size_scale) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 3usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).bit_rate_value_minus1) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(bit_rate_value_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cpb_size_value_minus1) as usize - ptr as usize }, - 132usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(cpb_size_value_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cbr_flag) as usize - ptr as usize }, - 260usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(cbr_flag) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).initial_cpb_removal_delay_length_minus1) as usize - - ptr as usize - }, - 292usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(initial_cpb_removal_delay_length_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).cpb_removal_delay_length_minus1) as usize - ptr as usize - }, - 296usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(cpb_removal_delay_length_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).dpb_output_delay_length_minus1) as usize - ptr as usize - }, - 300usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(dpb_output_delay_length_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).time_offset_length) as usize - ptr as usize }, - 304usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264HrdParameters), - "::", - stringify!(time_offset_length) - ) - ); -} +const _: () = { + ["Size of StdVideoH264HrdParameters"] + [::core::mem::size_of::() - 308usize]; + ["Alignment of StdVideoH264HrdParameters"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoH264HrdParameters::cpb_cnt_minus1"] + [::core::mem::offset_of!(StdVideoH264HrdParameters, cpb_cnt_minus1) - 0usize]; + ["Offset of field: StdVideoH264HrdParameters::bit_rate_scale"] + [::core::mem::offset_of!(StdVideoH264HrdParameters, bit_rate_scale) - 1usize]; + ["Offset of field: StdVideoH264HrdParameters::cpb_size_scale"] + [::core::mem::offset_of!(StdVideoH264HrdParameters, cpb_size_scale) - 2usize]; + ["Offset of field: StdVideoH264HrdParameters::reserved1"] + [::core::mem::offset_of!(StdVideoH264HrdParameters, reserved1) - 3usize]; + ["Offset of field: StdVideoH264HrdParameters::bit_rate_value_minus1"] + [::core::mem::offset_of!(StdVideoH264HrdParameters, bit_rate_value_minus1) - 4usize]; + ["Offset of field: StdVideoH264HrdParameters::cpb_size_value_minus1"] + [::core::mem::offset_of!(StdVideoH264HrdParameters, cpb_size_value_minus1) - 132usize]; + ["Offset of field: StdVideoH264HrdParameters::cbr_flag"] + [::core::mem::offset_of!(StdVideoH264HrdParameters, cbr_flag) - 260usize]; + ["Offset of field: StdVideoH264HrdParameters::initial_cpb_removal_delay_length_minus1"][::core::mem::offset_of!( + StdVideoH264HrdParameters, + initial_cpb_removal_delay_length_minus1 + ) + - 292usize]; + ["Offset of field: StdVideoH264HrdParameters::cpb_removal_delay_length_minus1"][::core::mem::offset_of!( + StdVideoH264HrdParameters, + cpb_removal_delay_length_minus1 + ) - 296usize]; + ["Offset of field: StdVideoH264HrdParameters::dpb_output_delay_length_minus1"][::core::mem::offset_of!( + StdVideoH264HrdParameters, + dpb_output_delay_length_minus1 + ) - 300usize]; + ["Offset of field: StdVideoH264HrdParameters::time_offset_length"] + [::core::mem::offset_of!(StdVideoH264HrdParameters, time_offset_length) - 304usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoH264SequenceParameterSetVui { @@ -620,190 +514,58 @@ pub struct StdVideoH264SequenceParameterSetVui { pub reserved1: u32, pub pHrdParameters: *const StdVideoH264HrdParameters, } -#[test] -fn bindgen_test_layout_StdVideoH264SequenceParameterSetVui() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 40usize, - concat!("Size of: ", stringify!(StdVideoH264SequenceParameterSetVui)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!( - "Alignment of ", - stringify!(StdVideoH264SequenceParameterSetVui) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).aspect_ratio_idc) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(aspect_ratio_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sar_width) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(sar_width) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sar_height) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(sar_height) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).video_format) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(video_format) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).colour_primaries) as usize - ptr as usize }, - 13usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(colour_primaries) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).transfer_characteristics) as usize - ptr as usize }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(transfer_characteristics) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).matrix_coefficients) as usize - ptr as usize }, - 15usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(matrix_coefficients) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_units_in_tick) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(num_units_in_tick) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).time_scale) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(time_scale) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).max_num_reorder_frames) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(max_num_reorder_frames) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).max_dec_frame_buffering) as usize - ptr as usize }, - 25usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(max_dec_frame_buffering) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).chroma_sample_loc_type_top_field) as usize - ptr as usize - }, - 26usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(chroma_sample_loc_type_top_field) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).chroma_sample_loc_type_bottom_field) as usize - - ptr as usize - }, - 27usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(chroma_sample_loc_type_bottom_field) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 28usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pHrdParameters) as usize - ptr as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSetVui), - "::", - stringify!(pHrdParameters) - ) - ); -} +const _: () = { + ["Size of StdVideoH264SequenceParameterSetVui"] + [::core::mem::size_of::() - 40usize]; + ["Alignment of StdVideoH264SequenceParameterSetVui"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::flags"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, flags) - 0usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::aspect_ratio_idc"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, aspect_ratio_idc) - 4usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::sar_width"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, sar_width) - 8usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::sar_height"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, sar_height) - 10usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::video_format"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, video_format) - 12usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::colour_primaries"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, colour_primaries) - 13usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::transfer_characteristics"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSetVui, + transfer_characteristics + ) - 14usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::matrix_coefficients"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSetVui, + matrix_coefficients + ) - 15usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::num_units_in_tick"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, num_units_in_tick) - 16usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::time_scale"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, time_scale) - 20usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::max_num_reorder_frames"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSetVui, + max_num_reorder_frames + ) - 24usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::max_dec_frame_buffering"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSetVui, + max_dec_frame_buffering + ) - 25usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::chroma_sample_loc_type_top_field"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSetVui, + chroma_sample_loc_type_top_field + ) + - 26usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::chroma_sample_loc_type_bottom_field"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSetVui, + chroma_sample_loc_type_bottom_field + ) + - 27usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::reserved1"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, reserved1) - 28usize]; + ["Offset of field: StdVideoH264SequenceParameterSetVui::pHrdParameters"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSetVui, pHrdParameters) - 32usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -812,19 +574,10 @@ pub struct StdVideoH264SpsFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 2usize]>, pub __bindgen_padding_0: u16, } -#[test] -fn bindgen_test_layout_StdVideoH264SpsFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH264SpsFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH264SpsFlags)) - ); -} +const _: () = { + ["Size of StdVideoH264SpsFlags"][::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH264SpsFlags"][::core::mem::align_of::() - 4usize]; +}; impl StdVideoH264SpsFlags { #[inline] pub fn constraint_set0_flag(&self) -> u32 { @@ -1105,64 +858,22 @@ pub struct StdVideoH264ScalingLists { pub ScalingList4x4: [[u8; 16usize]; 6usize], pub ScalingList8x8: [[u8; 64usize]; 6usize], } -#[test] -fn bindgen_test_layout_StdVideoH264ScalingLists() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 484usize, - concat!("Size of: ", stringify!(StdVideoH264ScalingLists)) - ); - assert_eq!( - ::core::mem::align_of::(), - 2usize, - concat!("Alignment of ", stringify!(StdVideoH264ScalingLists)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).scaling_list_present_mask) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264ScalingLists), - "::", - stringify!(scaling_list_present_mask) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).use_default_scaling_matrix_mask) as usize - ptr as usize - }, - 2usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264ScalingLists), - "::", - stringify!(use_default_scaling_matrix_mask) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ScalingList4x4) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264ScalingLists), - "::", - stringify!(ScalingList4x4) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ScalingList8x8) as usize - ptr as usize }, - 100usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264ScalingLists), - "::", - stringify!(ScalingList8x8) - ) - ); -} +const _: () = { + ["Size of StdVideoH264ScalingLists"] + [::core::mem::size_of::() - 484usize]; + ["Alignment of StdVideoH264ScalingLists"] + [::core::mem::align_of::() - 2usize]; + ["Offset of field: StdVideoH264ScalingLists::scaling_list_present_mask"] + [::core::mem::offset_of!(StdVideoH264ScalingLists, scaling_list_present_mask) - 0usize]; + ["Offset of field: StdVideoH264ScalingLists::use_default_scaling_matrix_mask"][::core::mem::offset_of!( + StdVideoH264ScalingLists, + use_default_scaling_matrix_mask + ) - 2usize]; + ["Offset of field: StdVideoH264ScalingLists::ScalingList4x4"] + [::core::mem::offset_of!(StdVideoH264ScalingLists, ScalingList4x4) - 4usize]; + ["Offset of field: StdVideoH264ScalingLists::ScalingList8x8"] + [::core::mem::offset_of!(StdVideoH264ScalingLists, ScalingList8x8) - 100usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoH264SequenceParameterSet { @@ -1192,284 +903,94 @@ pub struct StdVideoH264SequenceParameterSet { pub pScalingLists: *const StdVideoH264ScalingLists, pub pSequenceParameterSetVui: *const StdVideoH264SequenceParameterSetVui, } -#[test] -fn bindgen_test_layout_StdVideoH264SequenceParameterSet() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 88usize, - concat!("Size of: ", stringify!(StdVideoH264SequenceParameterSet)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!( - "Alignment of ", - stringify!(StdVideoH264SequenceParameterSet) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).profile_idc) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(profile_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).level_idc) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(level_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_format_idc) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(chroma_format_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).seq_parameter_set_id) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(seq_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).bit_depth_luma_minus8) as usize - ptr as usize }, - 17usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(bit_depth_luma_minus8) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).bit_depth_chroma_minus8) as usize - ptr as usize }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(bit_depth_chroma_minus8) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).log2_max_frame_num_minus4) as usize - ptr as usize }, - 19usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(log2_max_frame_num_minus4) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_order_cnt_type) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(pic_order_cnt_type) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).offset_for_non_ref_pic) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(offset_for_non_ref_pic) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).offset_for_top_to_bottom_field) as usize - ptr as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(offset_for_top_to_bottom_field) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_max_pic_order_cnt_lsb_minus4) as usize - ptr as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(log2_max_pic_order_cnt_lsb_minus4) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ref_frames_in_pic_order_cnt_cycle) as usize - - ptr as usize - }, - 33usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(num_ref_frames_in_pic_order_cnt_cycle) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).max_num_ref_frames) as usize - ptr as usize }, - 34usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(max_num_ref_frames) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 35usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_width_in_mbs_minus1) as usize - ptr as usize }, - 36usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(pic_width_in_mbs_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).pic_height_in_map_units_minus1) as usize - ptr as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(pic_height_in_map_units_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_crop_left_offset) as usize - ptr as usize }, - 44usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(frame_crop_left_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_crop_right_offset) as usize - ptr as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(frame_crop_right_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_crop_top_offset) as usize - ptr as usize }, - 52usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(frame_crop_top_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_crop_bottom_offset) as usize - ptr as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(frame_crop_bottom_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved2) as usize - ptr as usize }, - 60usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(reserved2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pOffsetForRefFrame) as usize - ptr as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(pOffsetForRefFrame) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pScalingLists) as usize - ptr as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(pScalingLists) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pSequenceParameterSetVui) as usize - ptr as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264SequenceParameterSet), - "::", - stringify!(pSequenceParameterSetVui) - ) - ); -} +const _: () = { + ["Size of StdVideoH264SequenceParameterSet"] + [::core::mem::size_of::() - 88usize]; + ["Alignment of StdVideoH264SequenceParameterSet"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::flags"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, flags) - 0usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::profile_idc"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, profile_idc) - 4usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::level_idc"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, level_idc) - 8usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::chroma_format_idc"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, chroma_format_idc) - 12usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::seq_parameter_set_id"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, seq_parameter_set_id) - 16usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::bit_depth_luma_minus8"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + bit_depth_luma_minus8 + ) - 17usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::bit_depth_chroma_minus8"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + bit_depth_chroma_minus8 + ) - 18usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::log2_max_frame_num_minus4"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + log2_max_frame_num_minus4 + ) - 19usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::pic_order_cnt_type"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, pic_order_cnt_type) - 20usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::offset_for_non_ref_pic"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + offset_for_non_ref_pic + ) - 24usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::offset_for_top_to_bottom_field"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + offset_for_top_to_bottom_field + ) + - 28usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::log2_max_pic_order_cnt_lsb_minus4"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + log2_max_pic_order_cnt_lsb_minus4 + ) + - 32usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::num_ref_frames_in_pic_order_cnt_cycle"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + num_ref_frames_in_pic_order_cnt_cycle + ) + - 33usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::max_num_ref_frames"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, max_num_ref_frames) - 34usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::reserved1"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, reserved1) - 35usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::pic_width_in_mbs_minus1"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + pic_width_in_mbs_minus1 + ) - 36usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::pic_height_in_map_units_minus1"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + pic_height_in_map_units_minus1 + ) + - 40usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::frame_crop_left_offset"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + frame_crop_left_offset + ) - 44usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::frame_crop_right_offset"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + frame_crop_right_offset + ) - 48usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::frame_crop_top_offset"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + frame_crop_top_offset + ) - 52usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::frame_crop_bottom_offset"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + frame_crop_bottom_offset + ) - 56usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::reserved2"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, reserved2) - 60usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::pOffsetForRefFrame"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, pOffsetForRefFrame) - 64usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::pScalingLists"] + [::core::mem::offset_of!(StdVideoH264SequenceParameterSet, pScalingLists) - 72usize]; + ["Offset of field: StdVideoH264SequenceParameterSet::pSequenceParameterSetVui"][::core::mem::offset_of!( + StdVideoH264SequenceParameterSet, + pSequenceParameterSetVui + ) - 80usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -1478,19 +999,10 @@ pub struct StdVideoH264PpsFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>, pub __bindgen_padding_0: [u8; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoH264PpsFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH264PpsFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH264PpsFlags)) - ); -} +const _: () = { + ["Size of StdVideoH264PpsFlags"][::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH264PpsFlags"][::core::mem::align_of::() - 4usize]; +}; impl StdVideoH264PpsFlags { #[inline] pub fn transform_8x8_mode_flag(&self) -> u32 { @@ -1649,140 +1161,45 @@ pub struct StdVideoH264PictureParameterSet { pub second_chroma_qp_index_offset: i8, pub pScalingLists: *const StdVideoH264ScalingLists, } -#[test] -fn bindgen_test_layout_StdVideoH264PictureParameterSet() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 24usize, - concat!("Size of: ", stringify!(StdVideoH264PictureParameterSet)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoH264PictureParameterSet)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).seq_parameter_set_id) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(seq_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_parameter_set_id) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(pic_parameter_set_id) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ref_idx_l0_default_active_minus1) as usize - - ptr as usize - }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(num_ref_idx_l0_default_active_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ref_idx_l1_default_active_minus1) as usize - - ptr as usize - }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(num_ref_idx_l1_default_active_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).weighted_bipred_idc) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(weighted_bipred_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_init_qp_minus26) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(pic_init_qp_minus26) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_init_qs_minus26) as usize - ptr as usize }, - 13usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(pic_init_qs_minus26) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_qp_index_offset) as usize - ptr as usize }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(chroma_qp_index_offset) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).second_chroma_qp_index_offset) as usize - ptr as usize - }, - 15usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(second_chroma_qp_index_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pScalingLists) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH264PictureParameterSet), - "::", - stringify!(pScalingLists) - ) - ); -} +const _: () = { + ["Size of StdVideoH264PictureParameterSet"] + [::core::mem::size_of::() - 24usize]; + ["Alignment of StdVideoH264PictureParameterSet"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoH264PictureParameterSet::flags"] + [::core::mem::offset_of!(StdVideoH264PictureParameterSet, flags) - 0usize]; + ["Offset of field: StdVideoH264PictureParameterSet::seq_parameter_set_id"] + [::core::mem::offset_of!(StdVideoH264PictureParameterSet, seq_parameter_set_id) - 4usize]; + ["Offset of field: StdVideoH264PictureParameterSet::pic_parameter_set_id"] + [::core::mem::offset_of!(StdVideoH264PictureParameterSet, pic_parameter_set_id) - 5usize]; + ["Offset of field: StdVideoH264PictureParameterSet::num_ref_idx_l0_default_active_minus1"][::core::mem::offset_of!( + StdVideoH264PictureParameterSet, + num_ref_idx_l0_default_active_minus1 + ) + - 6usize]; + ["Offset of field: StdVideoH264PictureParameterSet::num_ref_idx_l1_default_active_minus1"][::core::mem::offset_of!( + StdVideoH264PictureParameterSet, + num_ref_idx_l1_default_active_minus1 + ) + - 7usize]; + ["Offset of field: StdVideoH264PictureParameterSet::weighted_bipred_idc"] + [::core::mem::offset_of!(StdVideoH264PictureParameterSet, weighted_bipred_idc) - 8usize]; + ["Offset of field: StdVideoH264PictureParameterSet::pic_init_qp_minus26"] + [::core::mem::offset_of!(StdVideoH264PictureParameterSet, pic_init_qp_minus26) - 12usize]; + ["Offset of field: StdVideoH264PictureParameterSet::pic_init_qs_minus26"] + [::core::mem::offset_of!(StdVideoH264PictureParameterSet, pic_init_qs_minus26) - 13usize]; + ["Offset of field: StdVideoH264PictureParameterSet::chroma_qp_index_offset"][::core::mem::offset_of!( + StdVideoH264PictureParameterSet, + chroma_qp_index_offset + ) - 14usize]; + ["Offset of field: StdVideoH264PictureParameterSet::second_chroma_qp_index_offset"][::core::mem::offset_of!( + StdVideoH264PictureParameterSet, + second_chroma_qp_index_offset + ) + - 15usize]; + ["Offset of field: StdVideoH264PictureParameterSet::pScalingLists"] + [::core::mem::offset_of!(StdVideoH264PictureParameterSet, pScalingLists) - 16usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -1791,22 +1208,12 @@ pub struct StdVideoDecodeH264PictureInfoFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>, pub __bindgen_padding_0: [u8; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoDecodeH264PictureInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoDecodeH264PictureInfoFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoDecodeH264PictureInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeH264PictureInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoDecodeH264PictureInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoDecodeH264PictureInfoFlags { #[inline] pub fn field_pic_flag(&self) -> u32 { @@ -1924,102 +1331,28 @@ pub struct StdVideoDecodeH264PictureInfo { pub idr_pic_id: u16, pub PicOrderCnt: [i32; 2usize], } -#[test] -fn bindgen_test_layout_StdVideoDecodeH264PictureInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 20usize, - concat!("Size of: ", stringify!(StdVideoDecodeH264PictureInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoDecodeH264PictureInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264PictureInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).seq_parameter_set_id) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264PictureInfo), - "::", - stringify!(seq_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_parameter_set_id) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264PictureInfo), - "::", - stringify!(pic_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264PictureInfo), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved2) as usize - ptr as usize }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264PictureInfo), - "::", - stringify!(reserved2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_num) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264PictureInfo), - "::", - stringify!(frame_num) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).idr_pic_id) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264PictureInfo), - "::", - stringify!(idr_pic_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).PicOrderCnt) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264PictureInfo), - "::", - stringify!(PicOrderCnt) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeH264PictureInfo"] + [::core::mem::size_of::() - 20usize]; + ["Alignment of StdVideoDecodeH264PictureInfo"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoDecodeH264PictureInfo::flags"] + [::core::mem::offset_of!(StdVideoDecodeH264PictureInfo, flags) - 0usize]; + ["Offset of field: StdVideoDecodeH264PictureInfo::seq_parameter_set_id"] + [::core::mem::offset_of!(StdVideoDecodeH264PictureInfo, seq_parameter_set_id) - 4usize]; + ["Offset of field: StdVideoDecodeH264PictureInfo::pic_parameter_set_id"] + [::core::mem::offset_of!(StdVideoDecodeH264PictureInfo, pic_parameter_set_id) - 5usize]; + ["Offset of field: StdVideoDecodeH264PictureInfo::reserved1"] + [::core::mem::offset_of!(StdVideoDecodeH264PictureInfo, reserved1) - 6usize]; + ["Offset of field: StdVideoDecodeH264PictureInfo::reserved2"] + [::core::mem::offset_of!(StdVideoDecodeH264PictureInfo, reserved2) - 7usize]; + ["Offset of field: StdVideoDecodeH264PictureInfo::frame_num"] + [::core::mem::offset_of!(StdVideoDecodeH264PictureInfo, frame_num) - 8usize]; + ["Offset of field: StdVideoDecodeH264PictureInfo::idr_pic_id"] + [::core::mem::offset_of!(StdVideoDecodeH264PictureInfo, idr_pic_id) - 10usize]; + ["Offset of field: StdVideoDecodeH264PictureInfo::PicOrderCnt"] + [::core::mem::offset_of!(StdVideoDecodeH264PictureInfo, PicOrderCnt) - 12usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -2028,25 +1361,12 @@ pub struct StdVideoDecodeH264ReferenceInfoFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>, pub __bindgen_padding_0: [u8; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoDecodeH264ReferenceInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!( - "Size of: ", - stringify!(StdVideoDecodeH264ReferenceInfoFlags) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoDecodeH264ReferenceInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeH264ReferenceInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoDecodeH264ReferenceInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoDecodeH264ReferenceInfoFlags { #[inline] pub fn top_field_flag(&self) -> u32 { @@ -2128,62 +1448,20 @@ pub struct StdVideoDecodeH264ReferenceInfo { pub reserved: u16, pub PicOrderCnt: [i32; 2usize], } -#[test] -fn bindgen_test_layout_StdVideoDecodeH264ReferenceInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(StdVideoDecodeH264ReferenceInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoDecodeH264ReferenceInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264ReferenceInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).FrameNum) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264ReferenceInfo), - "::", - stringify!(FrameNum) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264ReferenceInfo), - "::", - stringify!(reserved) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).PicOrderCnt) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH264ReferenceInfo), - "::", - stringify!(PicOrderCnt) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeH264ReferenceInfo"] + [::core::mem::size_of::() - 16usize]; + ["Alignment of StdVideoDecodeH264ReferenceInfo"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoDecodeH264ReferenceInfo::flags"] + [::core::mem::offset_of!(StdVideoDecodeH264ReferenceInfo, flags) - 0usize]; + ["Offset of field: StdVideoDecodeH264ReferenceInfo::FrameNum"] + [::core::mem::offset_of!(StdVideoDecodeH264ReferenceInfo, FrameNum) - 4usize]; + ["Offset of field: StdVideoDecodeH264ReferenceInfo::reserved"] + [::core::mem::offset_of!(StdVideoDecodeH264ReferenceInfo, reserved) - 6usize]; + ["Offset of field: StdVideoDecodeH264ReferenceInfo::PicOrderCnt"] + [::core::mem::offset_of!(StdVideoDecodeH264ReferenceInfo, PicOrderCnt) - 8usize]; +}; pub const StdVideoH265ChromaFormatIdc_STD_VIDEO_H265_CHROMA_FORMAT_IDC_MONOCHROME: StdVideoH265ChromaFormatIdc = 0; pub const StdVideoH265ChromaFormatIdc_STD_VIDEO_H265_CHROMA_FORMAT_IDC_420: @@ -2280,54 +1558,18 @@ pub struct StdVideoH265DecPicBufMgr { pub max_dec_pic_buffering_minus1: [u8; 7usize], pub max_num_reorder_pics: [u8; 7usize], } -#[test] -fn bindgen_test_layout_StdVideoH265DecPicBufMgr() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 44usize, - concat!("Size of: ", stringify!(StdVideoH265DecPicBufMgr)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH265DecPicBufMgr)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).max_latency_increase_plus1) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265DecPicBufMgr), - "::", - stringify!(max_latency_increase_plus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).max_dec_pic_buffering_minus1) as usize - ptr as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265DecPicBufMgr), - "::", - stringify!(max_dec_pic_buffering_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).max_num_reorder_pics) as usize - ptr as usize }, - 35usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265DecPicBufMgr), - "::", - stringify!(max_num_reorder_pics) - ) - ); -} +const _: () = { + ["Size of StdVideoH265DecPicBufMgr"] + [::core::mem::size_of::() - 44usize]; + ["Alignment of StdVideoH265DecPicBufMgr"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoH265DecPicBufMgr::max_latency_increase_plus1"] + [::core::mem::offset_of!(StdVideoH265DecPicBufMgr, max_latency_increase_plus1) - 0usize]; + ["Offset of field: StdVideoH265DecPicBufMgr::max_dec_pic_buffering_minus1"] + [::core::mem::offset_of!(StdVideoH265DecPicBufMgr, max_dec_pic_buffering_minus1) - 28usize]; + ["Offset of field: StdVideoH265DecPicBufMgr::max_num_reorder_pics"] + [::core::mem::offset_of!(StdVideoH265DecPicBufMgr, max_num_reorder_pics) - 35usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoH265SubLayerHrdParameters { @@ -2337,75 +1579,30 @@ pub struct StdVideoH265SubLayerHrdParameters { pub bit_rate_du_value_minus1: [u32; 32usize], pub cbr_flag: u32, } -#[test] -fn bindgen_test_layout_StdVideoH265SubLayerHrdParameters() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 516usize, - concat!("Size of: ", stringify!(StdVideoH265SubLayerHrdParameters)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoH265SubLayerHrdParameters) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).bit_rate_value_minus1) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SubLayerHrdParameters), - "::", - stringify!(bit_rate_value_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cpb_size_value_minus1) as usize - ptr as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SubLayerHrdParameters), - "::", - stringify!(cpb_size_value_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cpb_size_du_value_minus1) as usize - ptr as usize }, - 256usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SubLayerHrdParameters), - "::", - stringify!(cpb_size_du_value_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).bit_rate_du_value_minus1) as usize - ptr as usize }, - 384usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SubLayerHrdParameters), - "::", - stringify!(bit_rate_du_value_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cbr_flag) as usize - ptr as usize }, - 512usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SubLayerHrdParameters), - "::", - stringify!(cbr_flag) - ) - ); -} +const _: () = { + ["Size of StdVideoH265SubLayerHrdParameters"] + [::core::mem::size_of::() - 516usize]; + ["Alignment of StdVideoH265SubLayerHrdParameters"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoH265SubLayerHrdParameters::bit_rate_value_minus1"][::core::mem::offset_of!( + StdVideoH265SubLayerHrdParameters, + bit_rate_value_minus1 + ) - 0usize]; + ["Offset of field: StdVideoH265SubLayerHrdParameters::cpb_size_value_minus1"][::core::mem::offset_of!( + StdVideoH265SubLayerHrdParameters, + cpb_size_value_minus1 + ) - 128usize]; + ["Offset of field: StdVideoH265SubLayerHrdParameters::cpb_size_du_value_minus1"][::core::mem::offset_of!( + StdVideoH265SubLayerHrdParameters, + cpb_size_du_value_minus1 + ) - 256usize]; + ["Offset of field: StdVideoH265SubLayerHrdParameters::bit_rate_du_value_minus1"][::core::mem::offset_of!( + StdVideoH265SubLayerHrdParameters, + bit_rate_du_value_minus1 + ) - 384usize]; + ["Offset of field: StdVideoH265SubLayerHrdParameters::cbr_flag"] + [::core::mem::offset_of!(StdVideoH265SubLayerHrdParameters, cbr_flag) - 512usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -2413,19 +1610,10 @@ pub struct StdVideoH265HrdFlags { pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoH265HrdFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH265HrdFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH265HrdFlags)) - ); -} +const _: () = { + ["Size of StdVideoH265HrdFlags"][::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH265HrdFlags"][::core::mem::align_of::() - 4usize]; +}; impl StdVideoH265HrdFlags { #[inline] pub fn nal_hrd_parameters_present_flag(&self) -> u32 { @@ -2571,186 +1759,56 @@ pub struct StdVideoH265HrdParameters { pub pSubLayerHrdParametersNal: *const StdVideoH265SubLayerHrdParameters, pub pSubLayerHrdParametersVcl: *const StdVideoH265SubLayerHrdParameters, } -#[test] -fn bindgen_test_layout_StdVideoH265HrdParameters() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 56usize, - concat!("Size of: ", stringify!(StdVideoH265HrdParameters)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoH265HrdParameters)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).tick_divisor_minus2) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(tick_divisor_minus2) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).du_cpb_removal_delay_increment_length_minus1) as usize - - ptr as usize - }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(du_cpb_removal_delay_increment_length_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).dpb_output_delay_du_length_minus1) as usize - ptr as usize - }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(dpb_output_delay_du_length_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).bit_rate_scale) as usize - ptr as usize }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(bit_rate_scale) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cpb_size_scale) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(cpb_size_scale) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cpb_size_du_scale) as usize - ptr as usize }, - 9usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(cpb_size_du_scale) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).initial_cpb_removal_delay_length_minus1) as usize - - ptr as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(initial_cpb_removal_delay_length_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).au_cpb_removal_delay_length_minus1) as usize - ptr as usize - }, - 11usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(au_cpb_removal_delay_length_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).dpb_output_delay_length_minus1) as usize - ptr as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(dpb_output_delay_length_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cpb_cnt_minus1) as usize - ptr as usize }, - 13usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(cpb_cnt_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).elemental_duration_in_tc_minus1) as usize - ptr as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(elemental_duration_in_tc_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize }, - 34usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(reserved) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pSubLayerHrdParametersNal) as usize - ptr as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(pSubLayerHrdParametersNal) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pSubLayerHrdParametersVcl) as usize - ptr as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265HrdParameters), - "::", - stringify!(pSubLayerHrdParametersVcl) - ) - ); -} +const _: () = { + ["Size of StdVideoH265HrdParameters"] + [::core::mem::size_of::() - 56usize]; + ["Alignment of StdVideoH265HrdParameters"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoH265HrdParameters::flags"] + [::core::mem::offset_of!(StdVideoH265HrdParameters, flags) - 0usize]; + ["Offset of field: StdVideoH265HrdParameters::tick_divisor_minus2"] + [::core::mem::offset_of!(StdVideoH265HrdParameters, tick_divisor_minus2) - 4usize]; + ["Offset of field: StdVideoH265HrdParameters::du_cpb_removal_delay_increment_length_minus1"][::core::mem::offset_of!( + StdVideoH265HrdParameters, + du_cpb_removal_delay_increment_length_minus1 + ) + - 5usize]; + ["Offset of field: StdVideoH265HrdParameters::dpb_output_delay_du_length_minus1"][::core::mem::offset_of!( + StdVideoH265HrdParameters, + dpb_output_delay_du_length_minus1 + ) - 6usize]; + ["Offset of field: StdVideoH265HrdParameters::bit_rate_scale"] + [::core::mem::offset_of!(StdVideoH265HrdParameters, bit_rate_scale) - 7usize]; + ["Offset of field: StdVideoH265HrdParameters::cpb_size_scale"] + [::core::mem::offset_of!(StdVideoH265HrdParameters, cpb_size_scale) - 8usize]; + ["Offset of field: StdVideoH265HrdParameters::cpb_size_du_scale"] + [::core::mem::offset_of!(StdVideoH265HrdParameters, cpb_size_du_scale) - 9usize]; + ["Offset of field: StdVideoH265HrdParameters::initial_cpb_removal_delay_length_minus1"][::core::mem::offset_of!( + StdVideoH265HrdParameters, + initial_cpb_removal_delay_length_minus1 + ) + - 10usize]; + ["Offset of field: StdVideoH265HrdParameters::au_cpb_removal_delay_length_minus1"][::core::mem::offset_of!( + StdVideoH265HrdParameters, + au_cpb_removal_delay_length_minus1 + ) - 11usize]; + ["Offset of field: StdVideoH265HrdParameters::dpb_output_delay_length_minus1"][::core::mem::offset_of!( + StdVideoH265HrdParameters, + dpb_output_delay_length_minus1 + ) - 12usize]; + ["Offset of field: StdVideoH265HrdParameters::cpb_cnt_minus1"] + [::core::mem::offset_of!(StdVideoH265HrdParameters, cpb_cnt_minus1) - 13usize]; + ["Offset of field: StdVideoH265HrdParameters::elemental_duration_in_tc_minus1"][::core::mem::offset_of!( + StdVideoH265HrdParameters, + elemental_duration_in_tc_minus1 + ) - 20usize]; + ["Offset of field: StdVideoH265HrdParameters::reserved"] + [::core::mem::offset_of!(StdVideoH265HrdParameters, reserved) - 34usize]; + ["Offset of field: StdVideoH265HrdParameters::pSubLayerHrdParametersNal"] + [::core::mem::offset_of!(StdVideoH265HrdParameters, pSubLayerHrdParametersNal) - 40usize]; + ["Offset of field: StdVideoH265HrdParameters::pSubLayerHrdParametersVcl"] + [::core::mem::offset_of!(StdVideoH265HrdParameters, pSubLayerHrdParametersVcl) - 48usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -2759,19 +1817,10 @@ pub struct StdVideoH265VpsFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>, pub __bindgen_padding_0: [u8; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoH265VpsFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH265VpsFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH265VpsFlags)) - ); -} +const _: () = { + ["Size of StdVideoH265VpsFlags"][::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH265VpsFlags"][::core::mem::align_of::() - 4usize]; +}; impl StdVideoH265VpsFlags { #[inline] pub fn vps_temporal_id_nesting_flag(&self) -> u32 { @@ -2856,22 +1905,12 @@ pub struct StdVideoH265ProfileTierLevelFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>, pub __bindgen_padding_0: [u8; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoH265ProfileTierLevelFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH265ProfileTierLevelFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoH265ProfileTierLevelFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoH265ProfileTierLevelFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH265ProfileTierLevelFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoH265ProfileTierLevelFlags { #[inline] pub fn general_tier_flag(&self) -> u32 { @@ -2971,52 +2010,18 @@ pub struct StdVideoH265ProfileTierLevel { pub general_profile_idc: StdVideoH265ProfileIdc, pub general_level_idc: StdVideoH265LevelIdc, } -#[test] -fn bindgen_test_layout_StdVideoH265ProfileTierLevel() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 12usize, - concat!("Size of: ", stringify!(StdVideoH265ProfileTierLevel)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH265ProfileTierLevel)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ProfileTierLevel), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).general_profile_idc) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ProfileTierLevel), - "::", - stringify!(general_profile_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).general_level_idc) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ProfileTierLevel), - "::", - stringify!(general_level_idc) - ) - ); -} +const _: () = { + ["Size of StdVideoH265ProfileTierLevel"] + [::core::mem::size_of::() - 12usize]; + ["Alignment of StdVideoH265ProfileTierLevel"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoH265ProfileTierLevel::flags"] + [::core::mem::offset_of!(StdVideoH265ProfileTierLevel, flags) - 0usize]; + ["Offset of field: StdVideoH265ProfileTierLevel::general_profile_idc"] + [::core::mem::offset_of!(StdVideoH265ProfileTierLevel, general_profile_idc) - 4usize]; + ["Offset of field: StdVideoH265ProfileTierLevel::general_level_idc"] + [::core::mem::offset_of!(StdVideoH265ProfileTierLevel, general_level_idc) - 8usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoH265VideoParameterSet { @@ -3033,144 +2038,43 @@ pub struct StdVideoH265VideoParameterSet { pub pHrdParameters: *const StdVideoH265HrdParameters, pub pProfileTierLevel: *const StdVideoH265ProfileTierLevel, } -#[test] -fn bindgen_test_layout_StdVideoH265VideoParameterSet() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 48usize, - concat!("Size of: ", stringify!(StdVideoH265VideoParameterSet)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoH265VideoParameterSet)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).vps_video_parameter_set_id) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(vps_video_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).vps_max_sub_layers_minus1) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(vps_max_sub_layers_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved2) as usize - ptr as usize }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(reserved2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).vps_num_units_in_tick) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(vps_num_units_in_tick) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).vps_time_scale) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(vps_time_scale) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).vps_num_ticks_poc_diff_one_minus1) as usize - ptr as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(vps_num_ticks_poc_diff_one_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved3) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(reserved3) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pDecPicBufMgr) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(pDecPicBufMgr) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pHrdParameters) as usize - ptr as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(pHrdParameters) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pProfileTierLevel) as usize - ptr as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265VideoParameterSet), - "::", - stringify!(pProfileTierLevel) - ) - ); -} +const _: () = { + ["Size of StdVideoH265VideoParameterSet"] + [::core::mem::size_of::() - 48usize]; + ["Alignment of StdVideoH265VideoParameterSet"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoH265VideoParameterSet::flags"] + [::core::mem::offset_of!(StdVideoH265VideoParameterSet, flags) - 0usize]; + ["Offset of field: StdVideoH265VideoParameterSet::vps_video_parameter_set_id"][::core::mem::offset_of!( + StdVideoH265VideoParameterSet, + vps_video_parameter_set_id + ) - 4usize]; + ["Offset of field: StdVideoH265VideoParameterSet::vps_max_sub_layers_minus1"][::core::mem::offset_of!( + StdVideoH265VideoParameterSet, + vps_max_sub_layers_minus1 + ) - 5usize]; + ["Offset of field: StdVideoH265VideoParameterSet::reserved1"] + [::core::mem::offset_of!(StdVideoH265VideoParameterSet, reserved1) - 6usize]; + ["Offset of field: StdVideoH265VideoParameterSet::reserved2"] + [::core::mem::offset_of!(StdVideoH265VideoParameterSet, reserved2) - 7usize]; + ["Offset of field: StdVideoH265VideoParameterSet::vps_num_units_in_tick"] + [::core::mem::offset_of!(StdVideoH265VideoParameterSet, vps_num_units_in_tick) - 8usize]; + ["Offset of field: StdVideoH265VideoParameterSet::vps_time_scale"] + [::core::mem::offset_of!(StdVideoH265VideoParameterSet, vps_time_scale) - 12usize]; + ["Offset of field: StdVideoH265VideoParameterSet::vps_num_ticks_poc_diff_one_minus1"][::core::mem::offset_of!( + StdVideoH265VideoParameterSet, + vps_num_ticks_poc_diff_one_minus1 + ) + - 16usize]; + ["Offset of field: StdVideoH265VideoParameterSet::reserved3"] + [::core::mem::offset_of!(StdVideoH265VideoParameterSet, reserved3) - 20usize]; + ["Offset of field: StdVideoH265VideoParameterSet::pDecPicBufMgr"] + [::core::mem::offset_of!(StdVideoH265VideoParameterSet, pDecPicBufMgr) - 24usize]; + ["Offset of field: StdVideoH265VideoParameterSet::pHrdParameters"] + [::core::mem::offset_of!(StdVideoH265VideoParameterSet, pHrdParameters) - 32usize]; + ["Offset of field: StdVideoH265VideoParameterSet::pProfileTierLevel"] + [::core::mem::offset_of!(StdVideoH265VideoParameterSet, pProfileTierLevel) - 40usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoH265ScalingLists { @@ -3181,82 +2085,24 @@ pub struct StdVideoH265ScalingLists { pub ScalingListDCCoef16x16: [u8; 6usize], pub ScalingListDCCoef32x32: [u8; 2usize], } -#[test] -fn bindgen_test_layout_StdVideoH265ScalingLists() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 1000usize, - concat!("Size of: ", stringify!(StdVideoH265ScalingLists)) - ); - assert_eq!( - ::core::mem::align_of::(), - 1usize, - concat!("Alignment of ", stringify!(StdVideoH265ScalingLists)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ScalingList4x4) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ScalingLists), - "::", - stringify!(ScalingList4x4) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ScalingList8x8) as usize - ptr as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ScalingLists), - "::", - stringify!(ScalingList8x8) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ScalingList16x16) as usize - ptr as usize }, - 480usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ScalingLists), - "::", - stringify!(ScalingList16x16) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ScalingList32x32) as usize - ptr as usize }, - 864usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ScalingLists), - "::", - stringify!(ScalingList32x32) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ScalingListDCCoef16x16) as usize - ptr as usize }, - 992usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ScalingLists), - "::", - stringify!(ScalingListDCCoef16x16) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ScalingListDCCoef32x32) as usize - ptr as usize }, - 998usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ScalingLists), - "::", - stringify!(ScalingListDCCoef32x32) - ) - ); -} +const _: () = { + ["Size of StdVideoH265ScalingLists"] + [::core::mem::size_of::() - 1000usize]; + ["Alignment of StdVideoH265ScalingLists"] + [::core::mem::align_of::() - 1usize]; + ["Offset of field: StdVideoH265ScalingLists::ScalingList4x4"] + [::core::mem::offset_of!(StdVideoH265ScalingLists, ScalingList4x4) - 0usize]; + ["Offset of field: StdVideoH265ScalingLists::ScalingList8x8"] + [::core::mem::offset_of!(StdVideoH265ScalingLists, ScalingList8x8) - 96usize]; + ["Offset of field: StdVideoH265ScalingLists::ScalingList16x16"] + [::core::mem::offset_of!(StdVideoH265ScalingLists, ScalingList16x16) - 480usize]; + ["Offset of field: StdVideoH265ScalingLists::ScalingList32x32"] + [::core::mem::offset_of!(StdVideoH265ScalingLists, ScalingList32x32) - 864usize]; + ["Offset of field: StdVideoH265ScalingLists::ScalingListDCCoef16x16"] + [::core::mem::offset_of!(StdVideoH265ScalingLists, ScalingListDCCoef16x16) - 992usize]; + ["Offset of field: StdVideoH265ScalingLists::ScalingListDCCoef32x32"] + [::core::mem::offset_of!(StdVideoH265ScalingLists, ScalingListDCCoef32x32) - 998usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -3265,19 +2111,11 @@ pub struct StdVideoH265SpsVuiFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 3usize]>, pub __bindgen_padding_0: u8, } -#[test] -fn bindgen_test_layout_StdVideoH265SpsVuiFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH265SpsVuiFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH265SpsVuiFlags)) - ); -} +const _: () = { + ["Size of StdVideoH265SpsVuiFlags"][::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH265SpsVuiFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoH265SpsVuiFlags { #[inline] pub fn aspect_ratio_info_present_flag(&self) -> u32 { @@ -3621,332 +2459,116 @@ pub struct StdVideoH265SequenceParameterSetVui { pub log2_max_mv_length_vertical: u8, pub pHrdParameters: *const StdVideoH265HrdParameters, } -#[test] -fn bindgen_test_layout_StdVideoH265SequenceParameterSetVui() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 56usize, - concat!("Size of: ", stringify!(StdVideoH265SequenceParameterSetVui)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!( - "Alignment of ", - stringify!(StdVideoH265SequenceParameterSetVui) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).aspect_ratio_idc) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(aspect_ratio_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sar_width) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(sar_width) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sar_height) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(sar_height) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).video_format) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(video_format) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).colour_primaries) as usize - ptr as usize }, - 13usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(colour_primaries) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).transfer_characteristics) as usize - ptr as usize }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(transfer_characteristics) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).matrix_coeffs) as usize - ptr as usize }, - 15usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(matrix_coeffs) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).chroma_sample_loc_type_top_field) as usize - ptr as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(chroma_sample_loc_type_top_field) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).chroma_sample_loc_type_bottom_field) as usize - - ptr as usize - }, - 17usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(chroma_sample_loc_type_bottom_field) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved2) as usize - ptr as usize }, - 19usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(reserved2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).def_disp_win_left_offset) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(def_disp_win_left_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).def_disp_win_right_offset) as usize - ptr as usize }, - 22usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(def_disp_win_right_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).def_disp_win_top_offset) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(def_disp_win_top_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).def_disp_win_bottom_offset) as usize - ptr as usize }, - 26usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(def_disp_win_bottom_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).vui_num_units_in_tick) as usize - ptr as usize }, - 28usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(vui_num_units_in_tick) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).vui_time_scale) as usize - ptr as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(vui_time_scale) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).vui_num_ticks_poc_diff_one_minus1) as usize - ptr as usize - }, - 36usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(vui_num_ticks_poc_diff_one_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).min_spatial_segmentation_idc) as usize - ptr as usize - }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(min_spatial_segmentation_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved3) as usize - ptr as usize }, - 42usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(reserved3) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).max_bytes_per_pic_denom) as usize - ptr as usize }, - 44usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(max_bytes_per_pic_denom) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).max_bits_per_min_cu_denom) as usize - ptr as usize }, - 45usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(max_bits_per_min_cu_denom) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_max_mv_length_horizontal) as usize - ptr as usize - }, - 46usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(log2_max_mv_length_horizontal) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_max_mv_length_vertical) as usize - ptr as usize - }, - 47usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(log2_max_mv_length_vertical) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pHrdParameters) as usize - ptr as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSetVui), - "::", - stringify!(pHrdParameters) - ) - ); -} +const _: () = { + ["Size of StdVideoH265SequenceParameterSetVui"] + [::core::mem::size_of::() - 56usize]; + ["Alignment of StdVideoH265SequenceParameterSetVui"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::flags"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, flags) - 0usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::aspect_ratio_idc"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, aspect_ratio_idc) - 4usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::sar_width"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, sar_width) - 8usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::sar_height"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, sar_height) - 10usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::video_format"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, video_format) - 12usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::colour_primaries"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, colour_primaries) - 13usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::transfer_characteristics"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + transfer_characteristics + ) - 14usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::matrix_coeffs"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, matrix_coeffs) - 15usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::chroma_sample_loc_type_top_field"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + chroma_sample_loc_type_top_field + ) + - 16usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::chroma_sample_loc_type_bottom_field"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + chroma_sample_loc_type_bottom_field + ) + - 17usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::reserved1"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, reserved1) - 18usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::reserved2"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, reserved2) - 19usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::def_disp_win_left_offset"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + def_disp_win_left_offset + ) - 20usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::def_disp_win_right_offset"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + def_disp_win_right_offset + ) + - 22usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::def_disp_win_top_offset"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + def_disp_win_top_offset + ) - 24usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::def_disp_win_bottom_offset"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + def_disp_win_bottom_offset + ) + - 26usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::vui_num_units_in_tick"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + vui_num_units_in_tick + ) - 28usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::vui_time_scale"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, vui_time_scale) - 32usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::vui_num_ticks_poc_diff_one_minus1"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + vui_num_ticks_poc_diff_one_minus1 + ) + - 36usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::min_spatial_segmentation_idc"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + min_spatial_segmentation_idc + ) + - 40usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::reserved3"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, reserved3) - 42usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::max_bytes_per_pic_denom"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + max_bytes_per_pic_denom + ) - 44usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::max_bits_per_min_cu_denom"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + max_bits_per_min_cu_denom + ) + - 45usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::log2_max_mv_length_horizontal"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + log2_max_mv_length_horizontal + ) + - 46usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::log2_max_mv_length_vertical"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSetVui, + log2_max_mv_length_vertical + ) + - 47usize]; + ["Offset of field: StdVideoH265SequenceParameterSetVui::pHrdParameters"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSetVui, pHrdParameters) - 48usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoH265PredictorPaletteEntries { pub PredictorPaletteEntries: [[u16; 128usize]; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoH265PredictorPaletteEntries() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 768usize, - concat!("Size of: ", stringify!(StdVideoH265PredictorPaletteEntries)) - ); - assert_eq!( - ::core::mem::align_of::(), - 2usize, - concat!( - "Alignment of ", - stringify!(StdVideoH265PredictorPaletteEntries) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).PredictorPaletteEntries) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PredictorPaletteEntries), - "::", - stringify!(PredictorPaletteEntries) - ) - ); -} +const _: () = { + ["Size of StdVideoH265PredictorPaletteEntries"] + [::core::mem::size_of::() - 768usize]; + ["Alignment of StdVideoH265PredictorPaletteEntries"] + [::core::mem::align_of::() - 2usize]; + ["Offset of field: StdVideoH265PredictorPaletteEntries::PredictorPaletteEntries"][::core::mem::offset_of!( + StdVideoH265PredictorPaletteEntries, + PredictorPaletteEntries + ) - 0usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -3954,19 +2576,10 @@ pub struct StdVideoH265SpsFlags { pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoH265SpsFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH265SpsFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH265SpsFlags)) - ); -} +const _: () = { + ["Size of StdVideoH265SpsFlags"][::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH265SpsFlags"][::core::mem::align_of::() - 4usize]; +}; impl StdVideoH265SpsFlags { #[inline] pub fn sps_temporal_id_nesting_flag(&self) -> u32 { @@ -4491,22 +3104,12 @@ pub struct StdVideoH265ShortTermRefPicSetFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>, pub __bindgen_padding_0: [u8; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoH265ShortTermRefPicSetFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH265ShortTermRefPicSetFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoH265ShortTermRefPicSetFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoH265ShortTermRefPicSetFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH265ShortTermRefPicSetFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoH265ShortTermRefPicSetFlags { #[inline] pub fn inter_ref_pic_set_prediction_flag(&self) -> u32 { @@ -4566,206 +3169,62 @@ pub struct StdVideoH265ShortTermRefPicSet { pub delta_poc_s0_minus1: [u16; 16usize], pub delta_poc_s1_minus1: [u16; 16usize], } -#[test] -fn bindgen_test_layout_StdVideoH265ShortTermRefPicSet() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 88usize, - concat!("Size of: ", stringify!(StdVideoH265ShortTermRefPicSet)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH265ShortTermRefPicSet)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_idx_minus1) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(delta_idx_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).use_delta_flag) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(use_delta_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).abs_delta_rps_minus1) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(abs_delta_rps_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).used_by_curr_pic_flag) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(used_by_curr_pic_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).used_by_curr_pic_s0_flag) as usize - ptr as usize }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(used_by_curr_pic_s0_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).used_by_curr_pic_s1_flag) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(used_by_curr_pic_s1_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved2) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(reserved2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved3) as usize - ptr as usize }, - 21usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(reserved3) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_negative_pics) as usize - ptr as usize }, - 22usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(num_negative_pics) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_positive_pics) as usize - ptr as usize }, - 23usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(num_positive_pics) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_poc_s0_minus1) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(delta_poc_s0_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_poc_s1_minus1) as usize - ptr as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265ShortTermRefPicSet), - "::", - stringify!(delta_poc_s1_minus1) - ) - ); -} +const _: () = { + ["Size of StdVideoH265ShortTermRefPicSet"] + [::core::mem::size_of::() - 88usize]; + ["Alignment of StdVideoH265ShortTermRefPicSet"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::flags"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, flags) - 0usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::delta_idx_minus1"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, delta_idx_minus1) - 4usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::use_delta_flag"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, use_delta_flag) - 8usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::abs_delta_rps_minus1"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, abs_delta_rps_minus1) - 10usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::used_by_curr_pic_flag"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, used_by_curr_pic_flag) - 12usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::used_by_curr_pic_s0_flag"][::core::mem::offset_of!( + StdVideoH265ShortTermRefPicSet, + used_by_curr_pic_s0_flag + ) - 14usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::used_by_curr_pic_s1_flag"][::core::mem::offset_of!( + StdVideoH265ShortTermRefPicSet, + used_by_curr_pic_s1_flag + ) - 16usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::reserved1"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, reserved1) - 18usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::reserved2"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, reserved2) - 20usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::reserved3"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, reserved3) - 21usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::num_negative_pics"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, num_negative_pics) - 22usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::num_positive_pics"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, num_positive_pics) - 23usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::delta_poc_s0_minus1"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, delta_poc_s0_minus1) - 24usize]; + ["Offset of field: StdVideoH265ShortTermRefPicSet::delta_poc_s1_minus1"] + [::core::mem::offset_of!(StdVideoH265ShortTermRefPicSet, delta_poc_s1_minus1) - 56usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoH265LongTermRefPicsSps { pub used_by_curr_pic_lt_sps_flag: u32, pub lt_ref_pic_poc_lsb_sps: [u32; 32usize], } -#[test] -fn bindgen_test_layout_StdVideoH265LongTermRefPicsSps() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 132usize, - concat!("Size of: ", stringify!(StdVideoH265LongTermRefPicsSps)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH265LongTermRefPicsSps)) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).used_by_curr_pic_lt_sps_flag) as usize - ptr as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265LongTermRefPicsSps), - "::", - stringify!(used_by_curr_pic_lt_sps_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).lt_ref_pic_poc_lsb_sps) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265LongTermRefPicsSps), - "::", - stringify!(lt_ref_pic_poc_lsb_sps) - ) - ); -} +const _: () = { + ["Size of StdVideoH265LongTermRefPicsSps"] + [::core::mem::size_of::() - 132usize]; + ["Alignment of StdVideoH265LongTermRefPicsSps"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoH265LongTermRefPicsSps::used_by_curr_pic_lt_sps_flag"][::core::mem::offset_of!( + StdVideoH265LongTermRefPicsSps, + used_by_curr_pic_lt_sps_flag + ) - 0usize]; + ["Offset of field: StdVideoH265LongTermRefPicsSps::lt_ref_pic_poc_lsb_sps"] + [::core::mem::offset_of!(StdVideoH265LongTermRefPicsSps, lt_ref_pic_poc_lsb_sps) - 4usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoH265SequenceParameterSet { @@ -4809,455 +3268,134 @@ pub struct StdVideoH265SequenceParameterSet { pub pSequenceParameterSetVui: *const StdVideoH265SequenceParameterSetVui, pub pPredictorPaletteEntries: *const StdVideoH265PredictorPaletteEntries, } -#[test] -fn bindgen_test_layout_StdVideoH265SequenceParameterSet() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 112usize, - concat!("Size of: ", stringify!(StdVideoH265SequenceParameterSet)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!( - "Alignment of ", - stringify!(StdVideoH265SequenceParameterSet) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_format_idc) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(chroma_format_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_width_in_luma_samples) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pic_width_in_luma_samples) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_height_in_luma_samples) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pic_height_in_luma_samples) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sps_video_parameter_set_id) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(sps_video_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sps_max_sub_layers_minus1) as usize - ptr as usize }, - 17usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(sps_max_sub_layers_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sps_seq_parameter_set_id) as usize - ptr as usize }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(sps_seq_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).bit_depth_luma_minus8) as usize - ptr as usize }, - 19usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(bit_depth_luma_minus8) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).bit_depth_chroma_minus8) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(bit_depth_chroma_minus8) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_max_pic_order_cnt_lsb_minus4) as usize - ptr as usize - }, - 21usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(log2_max_pic_order_cnt_lsb_minus4) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_min_luma_coding_block_size_minus3) as usize - - ptr as usize - }, - 22usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(log2_min_luma_coding_block_size_minus3) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_diff_max_min_luma_coding_block_size) as usize - - ptr as usize - }, - 23usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(log2_diff_max_min_luma_coding_block_size) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_min_luma_transform_block_size_minus2) as usize - - ptr as usize - }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(log2_min_luma_transform_block_size_minus2) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_diff_max_min_luma_transform_block_size) as usize - - ptr as usize - }, - 25usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(log2_diff_max_min_luma_transform_block_size) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).max_transform_hierarchy_depth_inter) as usize - - ptr as usize - }, - 26usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(max_transform_hierarchy_depth_inter) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).max_transform_hierarchy_depth_intra) as usize - - ptr as usize - }, - 27usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(max_transform_hierarchy_depth_intra) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_short_term_ref_pic_sets) as usize - ptr as usize - }, - 28usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(num_short_term_ref_pic_sets) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_long_term_ref_pics_sps) as usize - ptr as usize }, - 29usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(num_long_term_ref_pics_sps) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).pcm_sample_bit_depth_luma_minus1) as usize - ptr as usize - }, - 30usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pcm_sample_bit_depth_luma_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).pcm_sample_bit_depth_chroma_minus1) as usize - ptr as usize - }, - 31usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pcm_sample_bit_depth_chroma_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_min_pcm_luma_coding_block_size_minus3) as usize - - ptr as usize - }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(log2_min_pcm_luma_coding_block_size_minus3) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_diff_max_min_pcm_luma_coding_block_size) as usize - - ptr as usize - }, - 33usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(log2_diff_max_min_pcm_luma_coding_block_size) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 34usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved2) as usize - ptr as usize }, - 35usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(reserved2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).palette_max_size) as usize - ptr as usize }, - 36usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(palette_max_size) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).delta_palette_max_predictor_size) as usize - ptr as usize - }, - 37usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(delta_palette_max_predictor_size) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).motion_vector_resolution_control_idc) as usize - - ptr as usize - }, - 38usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(motion_vector_resolution_control_idc) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).sps_num_palette_predictor_initializers_minus1) as usize - - ptr as usize - }, - 39usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(sps_num_palette_predictor_initializers_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).conf_win_left_offset) as usize - ptr as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(conf_win_left_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).conf_win_right_offset) as usize - ptr as usize }, - 44usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(conf_win_right_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).conf_win_top_offset) as usize - ptr as usize }, - 48usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(conf_win_top_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).conf_win_bottom_offset) as usize - ptr as usize }, - 52usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(conf_win_bottom_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pProfileTierLevel) as usize - ptr as usize }, - 56usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pProfileTierLevel) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pDecPicBufMgr) as usize - ptr as usize }, - 64usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pDecPicBufMgr) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pScalingLists) as usize - ptr as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pScalingLists) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pShortTermRefPicSet) as usize - ptr as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pShortTermRefPicSet) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pLongTermRefPicsSps) as usize - ptr as usize }, - 88usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pLongTermRefPicsSps) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pSequenceParameterSetVui) as usize - ptr as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pSequenceParameterSetVui) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pPredictorPaletteEntries) as usize - ptr as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265SequenceParameterSet), - "::", - stringify!(pPredictorPaletteEntries) - ) - ); -} +const _: () = { + ["Size of StdVideoH265SequenceParameterSet"] + [::core::mem::size_of::() - 112usize]; + ["Alignment of StdVideoH265SequenceParameterSet"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::flags"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, flags) - 0usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::chroma_format_idc"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, chroma_format_idc) - 4usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pic_width_in_luma_samples"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + pic_width_in_luma_samples + ) - 8usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pic_height_in_luma_samples"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + pic_height_in_luma_samples + ) - 12usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::sps_video_parameter_set_id"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + sps_video_parameter_set_id + ) - 16usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::sps_max_sub_layers_minus1"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + sps_max_sub_layers_minus1 + ) - 17usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::sps_seq_parameter_set_id"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + sps_seq_parameter_set_id + ) - 18usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::bit_depth_luma_minus8"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + bit_depth_luma_minus8 + ) - 19usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::bit_depth_chroma_minus8"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + bit_depth_chroma_minus8 + ) - 20usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::log2_max_pic_order_cnt_lsb_minus4"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + log2_max_pic_order_cnt_lsb_minus4 + ) + - 21usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::log2_min_luma_coding_block_size_minus3"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + log2_min_luma_coding_block_size_minus3 + ) + - 22usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::log2_diff_max_min_luma_coding_block_size"] [:: core :: mem :: offset_of ! (StdVideoH265SequenceParameterSet , log2_diff_max_min_luma_coding_block_size) - 23usize] ; + ["Offset of field: StdVideoH265SequenceParameterSet::log2_min_luma_transform_block_size_minus2"] [:: core :: mem :: offset_of ! (StdVideoH265SequenceParameterSet , log2_min_luma_transform_block_size_minus2) - 24usize] ; + ["Offset of field: StdVideoH265SequenceParameterSet::log2_diff_max_min_luma_transform_block_size"] [:: core :: mem :: offset_of ! (StdVideoH265SequenceParameterSet , log2_diff_max_min_luma_transform_block_size) - 25usize] ; + ["Offset of field: StdVideoH265SequenceParameterSet::max_transform_hierarchy_depth_inter"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + max_transform_hierarchy_depth_inter + ) + - 26usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::max_transform_hierarchy_depth_intra"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + max_transform_hierarchy_depth_intra + ) + - 27usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::num_short_term_ref_pic_sets"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + num_short_term_ref_pic_sets + ) - 28usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::num_long_term_ref_pics_sps"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + num_long_term_ref_pics_sps + ) - 29usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pcm_sample_bit_depth_luma_minus1"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + pcm_sample_bit_depth_luma_minus1 + ) + - 30usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pcm_sample_bit_depth_chroma_minus1"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + pcm_sample_bit_depth_chroma_minus1 + ) + - 31usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::log2_min_pcm_luma_coding_block_size_minus3"] [:: core :: mem :: offset_of ! (StdVideoH265SequenceParameterSet , log2_min_pcm_luma_coding_block_size_minus3) - 32usize] ; + ["Offset of field: StdVideoH265SequenceParameterSet::log2_diff_max_min_pcm_luma_coding_block_size"] [:: core :: mem :: offset_of ! (StdVideoH265SequenceParameterSet , log2_diff_max_min_pcm_luma_coding_block_size) - 33usize] ; + ["Offset of field: StdVideoH265SequenceParameterSet::reserved1"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, reserved1) - 34usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::reserved2"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, reserved2) - 35usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::palette_max_size"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, palette_max_size) - 36usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::delta_palette_max_predictor_size"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + delta_palette_max_predictor_size + ) + - 37usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::motion_vector_resolution_control_idc"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + motion_vector_resolution_control_idc + ) + - 38usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::sps_num_palette_predictor_initializers_minus1"] [:: core :: mem :: offset_of ! (StdVideoH265SequenceParameterSet , sps_num_palette_predictor_initializers_minus1) - 39usize] ; + ["Offset of field: StdVideoH265SequenceParameterSet::conf_win_left_offset"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, conf_win_left_offset) - 40usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::conf_win_right_offset"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + conf_win_right_offset + ) - 44usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::conf_win_top_offset"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, conf_win_top_offset) - 48usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::conf_win_bottom_offset"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + conf_win_bottom_offset + ) - 52usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pProfileTierLevel"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, pProfileTierLevel) - 56usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pDecPicBufMgr"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, pDecPicBufMgr) - 64usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pScalingLists"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, pScalingLists) - 72usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pShortTermRefPicSet"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, pShortTermRefPicSet) - 80usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pLongTermRefPicsSps"] + [::core::mem::offset_of!(StdVideoH265SequenceParameterSet, pLongTermRefPicsSps) - 88usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pSequenceParameterSetVui"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + pSequenceParameterSetVui + ) - 96usize]; + ["Offset of field: StdVideoH265SequenceParameterSet::pPredictorPaletteEntries"][::core::mem::offset_of!( + StdVideoH265SequenceParameterSet, + pPredictorPaletteEntries + ) - 104usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -5265,19 +3403,10 @@ pub struct StdVideoH265PpsFlags { pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoH265PpsFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoH265PpsFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoH265PpsFlags)) - ); -} +const _: () = { + ["Size of StdVideoH265PpsFlags"][::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoH265PpsFlags"][::core::mem::align_of::() - 4usize]; +}; impl StdVideoH265PpsFlags { #[inline] pub fn dependent_slice_segments_enabled_flag(&self) -> u32 { @@ -5849,408 +3978,130 @@ pub struct StdVideoH265PictureParameterSet { pub pScalingLists: *const StdVideoH265ScalingLists, pub pPredictorPaletteEntries: *const StdVideoH265PredictorPaletteEntries, } -#[test] -fn bindgen_test_layout_StdVideoH265PictureParameterSet() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 144usize, - concat!("Size of: ", stringify!(StdVideoH265PictureParameterSet)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoH265PictureParameterSet)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_pic_parameter_set_id) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_pic_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_seq_parameter_set_id) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_seq_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sps_video_parameter_set_id) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(sps_video_parameter_set_id) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_extra_slice_header_bits) as usize - ptr as usize - }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(num_extra_slice_header_bits) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ref_idx_l0_default_active_minus1) as usize - - ptr as usize - }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(num_ref_idx_l0_default_active_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ref_idx_l1_default_active_minus1) as usize - - ptr as usize - }, - 9usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(num_ref_idx_l1_default_active_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).init_qp_minus26) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(init_qp_minus26) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).diff_cu_qp_delta_depth) as usize - ptr as usize }, - 11usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(diff_cu_qp_delta_depth) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_cb_qp_offset) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_cb_qp_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_cr_qp_offset) as usize - ptr as usize }, - 13usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_cr_qp_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_beta_offset_div2) as usize - ptr as usize }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_beta_offset_div2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_tc_offset_div2) as usize - ptr as usize }, - 15usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_tc_offset_div2) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_parallel_merge_level_minus2) as usize - ptr as usize - }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(log2_parallel_merge_level_minus2) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_max_transform_skip_block_size_minus2) as usize - - ptr as usize - }, - 17usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(log2_max_transform_skip_block_size_minus2) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).diff_cu_chroma_qp_offset_depth) as usize - ptr as usize - }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(diff_cu_chroma_qp_offset_depth) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).chroma_qp_offset_list_len_minus1) as usize - ptr as usize - }, - 19usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(chroma_qp_offset_list_len_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cb_qp_offset_list) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(cb_qp_offset_list) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cr_qp_offset_list) as usize - ptr as usize }, - 26usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(cr_qp_offset_list) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).log2_sao_offset_scale_luma) as usize - ptr as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(log2_sao_offset_scale_luma) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).log2_sao_offset_scale_chroma) as usize - ptr as usize - }, - 33usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(log2_sao_offset_scale_chroma) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_act_y_qp_offset_plus5) as usize - ptr as usize }, - 34usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_act_y_qp_offset_plus5) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_act_cb_qp_offset_plus5) as usize - ptr as usize }, - 35usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_act_cb_qp_offset_plus5) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_act_cr_qp_offset_plus3) as usize - ptr as usize }, - 36usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_act_cr_qp_offset_plus3) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).pps_num_palette_predictor_initializers) as usize - - ptr as usize - }, - 37usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pps_num_palette_predictor_initializers) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).luma_bit_depth_entry_minus8) as usize - ptr as usize - }, - 38usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(luma_bit_depth_entry_minus8) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).chroma_bit_depth_entry_minus8) as usize - ptr as usize - }, - 39usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(chroma_bit_depth_entry_minus8) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_tile_columns_minus1) as usize - ptr as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(num_tile_columns_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_tile_rows_minus1) as usize - ptr as usize }, - 41usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(num_tile_rows_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 42usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved2) as usize - ptr as usize }, - 43usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(reserved2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).column_width_minus1) as usize - ptr as usize }, - 44usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(column_width_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).row_height_minus1) as usize - ptr as usize }, - 82usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(row_height_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved3) as usize - ptr as usize }, - 124usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(reserved3) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pScalingLists) as usize - ptr as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pScalingLists) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pPredictorPaletteEntries) as usize - ptr as usize }, - 136usize, - concat!( - "Offset of field: ", - stringify!(StdVideoH265PictureParameterSet), - "::", - stringify!(pPredictorPaletteEntries) - ) - ); -} +const _: () = { + ["Size of StdVideoH265PictureParameterSet"] + [::core::mem::size_of::() - 144usize]; + ["Alignment of StdVideoH265PictureParameterSet"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoH265PictureParameterSet::flags"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, flags) - 0usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_pic_parameter_set_id"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + pps_pic_parameter_set_id + ) - 4usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_seq_parameter_set_id"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + pps_seq_parameter_set_id + ) - 5usize]; + ["Offset of field: StdVideoH265PictureParameterSet::sps_video_parameter_set_id"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + sps_video_parameter_set_id + ) - 6usize]; + ["Offset of field: StdVideoH265PictureParameterSet::num_extra_slice_header_bits"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + num_extra_slice_header_bits + ) - 7usize]; + ["Offset of field: StdVideoH265PictureParameterSet::num_ref_idx_l0_default_active_minus1"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + num_ref_idx_l0_default_active_minus1 + ) + - 8usize]; + ["Offset of field: StdVideoH265PictureParameterSet::num_ref_idx_l1_default_active_minus1"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + num_ref_idx_l1_default_active_minus1 + ) + - 9usize]; + ["Offset of field: StdVideoH265PictureParameterSet::init_qp_minus26"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, init_qp_minus26) - 10usize]; + ["Offset of field: StdVideoH265PictureParameterSet::diff_cu_qp_delta_depth"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + diff_cu_qp_delta_depth + ) - 11usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_cb_qp_offset"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, pps_cb_qp_offset) - 12usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_cr_qp_offset"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, pps_cr_qp_offset) - 13usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_beta_offset_div2"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, pps_beta_offset_div2) - 14usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_tc_offset_div2"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, pps_tc_offset_div2) - 15usize]; + ["Offset of field: StdVideoH265PictureParameterSet::log2_parallel_merge_level_minus2"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + log2_parallel_merge_level_minus2 + ) + - 16usize]; + ["Offset of field: StdVideoH265PictureParameterSet::log2_max_transform_skip_block_size_minus2"] [:: core :: mem :: offset_of ! (StdVideoH265PictureParameterSet , log2_max_transform_skip_block_size_minus2) - 17usize] ; + ["Offset of field: StdVideoH265PictureParameterSet::diff_cu_chroma_qp_offset_depth"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + diff_cu_chroma_qp_offset_depth + ) + - 18usize]; + ["Offset of field: StdVideoH265PictureParameterSet::chroma_qp_offset_list_len_minus1"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + chroma_qp_offset_list_len_minus1 + ) + - 19usize]; + ["Offset of field: StdVideoH265PictureParameterSet::cb_qp_offset_list"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, cb_qp_offset_list) - 20usize]; + ["Offset of field: StdVideoH265PictureParameterSet::cr_qp_offset_list"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, cr_qp_offset_list) - 26usize]; + ["Offset of field: StdVideoH265PictureParameterSet::log2_sao_offset_scale_luma"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + log2_sao_offset_scale_luma + ) - 32usize]; + ["Offset of field: StdVideoH265PictureParameterSet::log2_sao_offset_scale_chroma"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + log2_sao_offset_scale_chroma + ) - 33usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_act_y_qp_offset_plus5"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + pps_act_y_qp_offset_plus5 + ) - 34usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_act_cb_qp_offset_plus5"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + pps_act_cb_qp_offset_plus5 + ) - 35usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_act_cr_qp_offset_plus3"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + pps_act_cr_qp_offset_plus3 + ) - 36usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pps_num_palette_predictor_initializers"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + pps_num_palette_predictor_initializers + ) + - 37usize]; + ["Offset of field: StdVideoH265PictureParameterSet::luma_bit_depth_entry_minus8"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + luma_bit_depth_entry_minus8 + ) - 38usize]; + ["Offset of field: StdVideoH265PictureParameterSet::chroma_bit_depth_entry_minus8"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + chroma_bit_depth_entry_minus8 + ) + - 39usize]; + ["Offset of field: StdVideoH265PictureParameterSet::num_tile_columns_minus1"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + num_tile_columns_minus1 + ) - 40usize]; + ["Offset of field: StdVideoH265PictureParameterSet::num_tile_rows_minus1"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, num_tile_rows_minus1) - 41usize]; + ["Offset of field: StdVideoH265PictureParameterSet::reserved1"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, reserved1) - 42usize]; + ["Offset of field: StdVideoH265PictureParameterSet::reserved2"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, reserved2) - 43usize]; + ["Offset of field: StdVideoH265PictureParameterSet::column_width_minus1"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, column_width_minus1) - 44usize]; + ["Offset of field: StdVideoH265PictureParameterSet::row_height_minus1"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, row_height_minus1) - 82usize]; + ["Offset of field: StdVideoH265PictureParameterSet::reserved3"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, reserved3) - 124usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pScalingLists"] + [::core::mem::offset_of!(StdVideoH265PictureParameterSet, pScalingLists) - 128usize]; + ["Offset of field: StdVideoH265PictureParameterSet::pPredictorPaletteEntries"][::core::mem::offset_of!( + StdVideoH265PictureParameterSet, + pPredictorPaletteEntries + ) - 136usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -6259,22 +4110,12 @@ pub struct StdVideoDecodeH265PictureInfoFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>, pub __bindgen_padding_0: [u8; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoDecodeH265PictureInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoDecodeH265PictureInfoFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoDecodeH265PictureInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeH265PictureInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoDecodeH265PictureInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoDecodeH265PictureInfoFlags { #[inline] pub fn IrapPicFlag(&self) -> u32 { @@ -6363,134 +4204,38 @@ pub struct StdVideoDecodeH265PictureInfo { pub RefPicSetStCurrAfter: [u8; 8usize], pub RefPicSetLtCurr: [u8; 8usize], } -#[test] -fn bindgen_test_layout_StdVideoDecodeH265PictureInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 40usize, - concat!("Size of: ", stringify!(StdVideoDecodeH265PictureInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoDecodeH265PictureInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sps_video_parameter_set_id) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(sps_video_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_seq_parameter_set_id) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(pps_seq_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_pic_parameter_set_id) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(pps_pic_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).NumDeltaPocsOfRefRpsIdx) as usize - ptr as usize }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(NumDeltaPocsOfRefRpsIdx) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).PicOrderCntVal) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(PicOrderCntVal) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).NumBitsForSTRefPicSetInSlice) as usize - ptr as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(NumBitsForSTRefPicSetInSlice) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved) as usize - ptr as usize }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(reserved) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).RefPicSetStCurrBefore) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(RefPicSetStCurrBefore) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).RefPicSetStCurrAfter) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(RefPicSetStCurrAfter) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).RefPicSetLtCurr) as usize - ptr as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265PictureInfo), - "::", - stringify!(RefPicSetLtCurr) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeH265PictureInfo"] + [::core::mem::size_of::() - 40usize]; + ["Alignment of StdVideoDecodeH265PictureInfo"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::flags"] + [::core::mem::offset_of!(StdVideoDecodeH265PictureInfo, flags) - 0usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::sps_video_parameter_set_id"][::core::mem::offset_of!( + StdVideoDecodeH265PictureInfo, + sps_video_parameter_set_id + ) - 4usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::pps_seq_parameter_set_id"] + [::core::mem::offset_of!(StdVideoDecodeH265PictureInfo, pps_seq_parameter_set_id) - 5usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::pps_pic_parameter_set_id"] + [::core::mem::offset_of!(StdVideoDecodeH265PictureInfo, pps_pic_parameter_set_id) - 6usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::NumDeltaPocsOfRefRpsIdx"] + [::core::mem::offset_of!(StdVideoDecodeH265PictureInfo, NumDeltaPocsOfRefRpsIdx) - 7usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::PicOrderCntVal"] + [::core::mem::offset_of!(StdVideoDecodeH265PictureInfo, PicOrderCntVal) - 8usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::NumBitsForSTRefPicSetInSlice"][::core::mem::offset_of!( + StdVideoDecodeH265PictureInfo, + NumBitsForSTRefPicSetInSlice + ) - 12usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::reserved"] + [::core::mem::offset_of!(StdVideoDecodeH265PictureInfo, reserved) - 14usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::RefPicSetStCurrBefore"] + [::core::mem::offset_of!(StdVideoDecodeH265PictureInfo, RefPicSetStCurrBefore) - 16usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::RefPicSetStCurrAfter"] + [::core::mem::offset_of!(StdVideoDecodeH265PictureInfo, RefPicSetStCurrAfter) - 24usize]; + ["Offset of field: StdVideoDecodeH265PictureInfo::RefPicSetLtCurr"] + [::core::mem::offset_of!(StdVideoDecodeH265PictureInfo, RefPicSetLtCurr) - 32usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -6499,25 +4244,12 @@ pub struct StdVideoDecodeH265ReferenceInfoFlags { pub _bitfield_1: __BindgenBitfieldUnit<[u8; 1usize]>, pub __bindgen_padding_0: [u8; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoDecodeH265ReferenceInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!( - "Size of: ", - stringify!(StdVideoDecodeH265ReferenceInfoFlags) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoDecodeH265ReferenceInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeH265ReferenceInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoDecodeH265ReferenceInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoDecodeH265ReferenceInfoFlags { #[inline] pub fn used_for_long_term_reference(&self) -> u32 { @@ -6565,42 +4297,16 @@ pub struct StdVideoDecodeH265ReferenceInfo { pub flags: StdVideoDecodeH265ReferenceInfoFlags, pub PicOrderCntVal: i32, } -#[test] -fn bindgen_test_layout_StdVideoDecodeH265ReferenceInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(StdVideoDecodeH265ReferenceInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoDecodeH265ReferenceInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265ReferenceInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).PicOrderCntVal) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeH265ReferenceInfo), - "::", - stringify!(PicOrderCntVal) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeH265ReferenceInfo"] + [::core::mem::size_of::() - 8usize]; + ["Alignment of StdVideoDecodeH265ReferenceInfo"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoDecodeH265ReferenceInfo::flags"] + [::core::mem::offset_of!(StdVideoDecodeH265ReferenceInfo, flags) - 0usize]; + ["Offset of field: StdVideoDecodeH265ReferenceInfo::PicOrderCntVal"] + [::core::mem::offset_of!(StdVideoDecodeH265ReferenceInfo, PicOrderCntVal) - 4usize]; +}; pub const StdVideoAV1Profile_STD_VIDEO_AV1_PROFILE_MAIN: StdVideoAV1Profile = 0; pub const StdVideoAV1Profile_STD_VIDEO_AV1_PROFILE_HIGH: StdVideoAV1Profile = 1; pub const StdVideoAV1Profile_STD_VIDEO_AV1_PROFILE_PROFESSIONAL: StdVideoAV1Profile = 2; @@ -6782,19 +4488,12 @@ pub struct StdVideoAV1ColorConfigFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoAV1ColorConfigFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoAV1ColorConfigFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1ColorConfigFlags)) - ); -} +const _: () = { + ["Size of StdVideoAV1ColorConfigFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoAV1ColorConfigFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoAV1ColorConfigFlags { #[inline] pub fn mono_chrome(&self) -> u32 { @@ -6897,131 +4596,41 @@ pub struct StdVideoAV1ColorConfig { pub matrix_coefficients: StdVideoAV1MatrixCoefficients, pub chroma_sample_position: StdVideoAV1ChromaSamplePosition, } -#[test] -fn bindgen_test_layout_StdVideoAV1ColorConfig() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 24usize, - concat!("Size of: ", stringify!(StdVideoAV1ColorConfig)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1ColorConfig)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1ColorConfig), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).BitDepth) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1ColorConfig), - "::", - stringify!(BitDepth) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).subsampling_x) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1ColorConfig), - "::", - stringify!(subsampling_x) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).subsampling_y) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1ColorConfig), - "::", - stringify!(subsampling_y) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1ColorConfig), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).color_primaries) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1ColorConfig), - "::", - stringify!(color_primaries) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).transfer_characteristics) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1ColorConfig), - "::", - stringify!(transfer_characteristics) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).matrix_coefficients) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1ColorConfig), - "::", - stringify!(matrix_coefficients) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_sample_position) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1ColorConfig), - "::", - stringify!(chroma_sample_position) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1ColorConfig"][::core::mem::size_of::() - 24usize]; + ["Alignment of StdVideoAV1ColorConfig"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoAV1ColorConfig::flags"] + [::core::mem::offset_of!(StdVideoAV1ColorConfig, flags) - 0usize]; + ["Offset of field: StdVideoAV1ColorConfig::BitDepth"] + [::core::mem::offset_of!(StdVideoAV1ColorConfig, BitDepth) - 4usize]; + ["Offset of field: StdVideoAV1ColorConfig::subsampling_x"] + [::core::mem::offset_of!(StdVideoAV1ColorConfig, subsampling_x) - 5usize]; + ["Offset of field: StdVideoAV1ColorConfig::subsampling_y"] + [::core::mem::offset_of!(StdVideoAV1ColorConfig, subsampling_y) - 6usize]; + ["Offset of field: StdVideoAV1ColorConfig::reserved1"] + [::core::mem::offset_of!(StdVideoAV1ColorConfig, reserved1) - 7usize]; + ["Offset of field: StdVideoAV1ColorConfig::color_primaries"] + [::core::mem::offset_of!(StdVideoAV1ColorConfig, color_primaries) - 8usize]; + ["Offset of field: StdVideoAV1ColorConfig::transfer_characteristics"] + [::core::mem::offset_of!(StdVideoAV1ColorConfig, transfer_characteristics) - 12usize]; + ["Offset of field: StdVideoAV1ColorConfig::matrix_coefficients"] + [::core::mem::offset_of!(StdVideoAV1ColorConfig, matrix_coefficients) - 16usize]; + ["Offset of field: StdVideoAV1ColorConfig::chroma_sample_position"] + [::core::mem::offset_of!(StdVideoAV1ColorConfig, chroma_sample_position) - 20usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoAV1TimingInfoFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoAV1TimingInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoAV1TimingInfoFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1TimingInfoFlags)) - ); -} +const _: () = { + ["Size of StdVideoAV1TimingInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoAV1TimingInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoAV1TimingInfoFlags { #[inline] pub fn equal_picture_interval(&self) -> u32 { @@ -7071,83 +4680,31 @@ pub struct StdVideoAV1TimingInfo { pub time_scale: u32, pub num_ticks_per_picture_minus_1: u32, } -#[test] -fn bindgen_test_layout_StdVideoAV1TimingInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(StdVideoAV1TimingInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1TimingInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TimingInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_units_in_display_tick) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TimingInfo), - "::", - stringify!(num_units_in_display_tick) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).time_scale) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TimingInfo), - "::", - stringify!(time_scale) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ticks_per_picture_minus_1) as usize - ptr as usize - }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TimingInfo), - "::", - stringify!(num_ticks_per_picture_minus_1) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1TimingInfo"][::core::mem::size_of::() - 16usize]; + ["Alignment of StdVideoAV1TimingInfo"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoAV1TimingInfo::flags"] + [::core::mem::offset_of!(StdVideoAV1TimingInfo, flags) - 0usize]; + ["Offset of field: StdVideoAV1TimingInfo::num_units_in_display_tick"] + [::core::mem::offset_of!(StdVideoAV1TimingInfo, num_units_in_display_tick) - 4usize]; + ["Offset of field: StdVideoAV1TimingInfo::time_scale"] + [::core::mem::offset_of!(StdVideoAV1TimingInfo, time_scale) - 8usize]; + ["Offset of field: StdVideoAV1TimingInfo::num_ticks_per_picture_minus_1"] + [::core::mem::offset_of!(StdVideoAV1TimingInfo, num_ticks_per_picture_minus_1) - 12usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoAV1LoopFilterFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoAV1LoopFilterFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoAV1LoopFilterFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1LoopFilterFlags)) - ); -} +const _: () = { + ["Size of StdVideoAV1LoopFilterFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoAV1LoopFilterFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoAV1LoopFilterFlags { #[inline] pub fn loop_filter_delta_enabled(&self) -> u32 { @@ -7217,111 +4774,37 @@ pub struct StdVideoAV1LoopFilter { pub update_mode_delta: u8, pub loop_filter_mode_deltas: [i8; 2usize], } -#[test] -fn bindgen_test_layout_StdVideoAV1LoopFilter() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 24usize, - concat!("Size of: ", stringify!(StdVideoAV1LoopFilter)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1LoopFilter)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1LoopFilter), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).loop_filter_level) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1LoopFilter), - "::", - stringify!(loop_filter_level) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).loop_filter_sharpness) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1LoopFilter), - "::", - stringify!(loop_filter_sharpness) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).update_ref_delta) as usize - ptr as usize }, - 9usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1LoopFilter), - "::", - stringify!(update_ref_delta) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).loop_filter_ref_deltas) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1LoopFilter), - "::", - stringify!(loop_filter_ref_deltas) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).update_mode_delta) as usize - ptr as usize }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1LoopFilter), - "::", - stringify!(update_mode_delta) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).loop_filter_mode_deltas) as usize - ptr as usize }, - 19usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1LoopFilter), - "::", - stringify!(loop_filter_mode_deltas) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1LoopFilter"][::core::mem::size_of::() - 24usize]; + ["Alignment of StdVideoAV1LoopFilter"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoAV1LoopFilter::flags"] + [::core::mem::offset_of!(StdVideoAV1LoopFilter, flags) - 0usize]; + ["Offset of field: StdVideoAV1LoopFilter::loop_filter_level"] + [::core::mem::offset_of!(StdVideoAV1LoopFilter, loop_filter_level) - 4usize]; + ["Offset of field: StdVideoAV1LoopFilter::loop_filter_sharpness"] + [::core::mem::offset_of!(StdVideoAV1LoopFilter, loop_filter_sharpness) - 8usize]; + ["Offset of field: StdVideoAV1LoopFilter::update_ref_delta"] + [::core::mem::offset_of!(StdVideoAV1LoopFilter, update_ref_delta) - 9usize]; + ["Offset of field: StdVideoAV1LoopFilter::loop_filter_ref_deltas"] + [::core::mem::offset_of!(StdVideoAV1LoopFilter, loop_filter_ref_deltas) - 10usize]; + ["Offset of field: StdVideoAV1LoopFilter::update_mode_delta"] + [::core::mem::offset_of!(StdVideoAV1LoopFilter, update_mode_delta) - 18usize]; + ["Offset of field: StdVideoAV1LoopFilter::loop_filter_mode_deltas"] + [::core::mem::offset_of!(StdVideoAV1LoopFilter, loop_filter_mode_deltas) - 19usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoAV1QuantizationFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoAV1QuantizationFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoAV1QuantizationFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1QuantizationFlags)) - ); -} +const _: () = { + ["Size of StdVideoAV1QuantizationFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoAV1QuantizationFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoAV1QuantizationFlags { #[inline] pub fn using_qmatrix(&self) -> u32 { @@ -7392,183 +4875,60 @@ pub struct StdVideoAV1Quantization { pub qm_u: u8, pub qm_v: u8, } -#[test] -fn bindgen_test_layout_StdVideoAV1Quantization() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(StdVideoAV1Quantization)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1Quantization)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).base_q_idx) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(base_q_idx) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).DeltaQYDc) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(DeltaQYDc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).DeltaQUDc) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(DeltaQUDc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).DeltaQUAc) as usize - ptr as usize }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(DeltaQUAc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).DeltaQVDc) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(DeltaQVDc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).DeltaQVAc) as usize - ptr as usize }, - 9usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(DeltaQVAc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).qm_y) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(qm_y) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).qm_u) as usize - ptr as usize }, - 11usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(qm_u) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).qm_v) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Quantization), - "::", - stringify!(qm_v) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1Quantization"] + [::core::mem::size_of::() - 16usize]; + ["Alignment of StdVideoAV1Quantization"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoAV1Quantization::flags"] + [::core::mem::offset_of!(StdVideoAV1Quantization, flags) - 0usize]; + ["Offset of field: StdVideoAV1Quantization::base_q_idx"] + [::core::mem::offset_of!(StdVideoAV1Quantization, base_q_idx) - 4usize]; + ["Offset of field: StdVideoAV1Quantization::DeltaQYDc"] + [::core::mem::offset_of!(StdVideoAV1Quantization, DeltaQYDc) - 5usize]; + ["Offset of field: StdVideoAV1Quantization::DeltaQUDc"] + [::core::mem::offset_of!(StdVideoAV1Quantization, DeltaQUDc) - 6usize]; + ["Offset of field: StdVideoAV1Quantization::DeltaQUAc"] + [::core::mem::offset_of!(StdVideoAV1Quantization, DeltaQUAc) - 7usize]; + ["Offset of field: StdVideoAV1Quantization::DeltaQVDc"] + [::core::mem::offset_of!(StdVideoAV1Quantization, DeltaQVDc) - 8usize]; + ["Offset of field: StdVideoAV1Quantization::DeltaQVAc"] + [::core::mem::offset_of!(StdVideoAV1Quantization, DeltaQVAc) - 9usize]; + ["Offset of field: StdVideoAV1Quantization::qm_y"] + [::core::mem::offset_of!(StdVideoAV1Quantization, qm_y) - 10usize]; + ["Offset of field: StdVideoAV1Quantization::qm_u"] + [::core::mem::offset_of!(StdVideoAV1Quantization, qm_u) - 11usize]; + ["Offset of field: StdVideoAV1Quantization::qm_v"] + [::core::mem::offset_of!(StdVideoAV1Quantization, qm_v) - 12usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoAV1Segmentation { pub FeatureEnabled: [u8; 8usize], pub FeatureData: [[i16; 8usize]; 8usize], } -#[test] -fn bindgen_test_layout_StdVideoAV1Segmentation() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 136usize, - concat!("Size of: ", stringify!(StdVideoAV1Segmentation)) - ); - assert_eq!( - ::core::mem::align_of::(), - 2usize, - concat!("Alignment of ", stringify!(StdVideoAV1Segmentation)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).FeatureEnabled) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Segmentation), - "::", - stringify!(FeatureEnabled) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).FeatureData) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1Segmentation), - "::", - stringify!(FeatureData) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1Segmentation"] + [::core::mem::size_of::() - 136usize]; + ["Alignment of StdVideoAV1Segmentation"] + [::core::mem::align_of::() - 2usize]; + ["Offset of field: StdVideoAV1Segmentation::FeatureEnabled"] + [::core::mem::offset_of!(StdVideoAV1Segmentation, FeatureEnabled) - 0usize]; + ["Offset of field: StdVideoAV1Segmentation::FeatureData"] + [::core::mem::offset_of!(StdVideoAV1Segmentation, FeatureData) - 8usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoAV1TileInfoFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoAV1TileInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoAV1TileInfoFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1TileInfoFlags)) - ); -} +const _: () = { + ["Size of StdVideoAV1TileInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoAV1TileInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoAV1TileInfoFlags { #[inline] pub fn uniform_tile_spacing_flag(&self) -> u32 { @@ -7624,122 +4984,30 @@ pub struct StdVideoAV1TileInfo { pub pWidthInSbsMinus1: *const u16, pub pHeightInSbsMinus1: *const u16, } -#[test] -fn bindgen_test_layout_StdVideoAV1TileInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 48usize, - concat!("Size of: ", stringify!(StdVideoAV1TileInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoAV1TileInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).TileCols) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(TileCols) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).TileRows) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(TileRows) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).context_update_tile_id) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(context_update_tile_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).tile_size_bytes_minus_1) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(tile_size_bytes_minus_1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 9usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pMiColStarts) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(pMiColStarts) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pMiRowStarts) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(pMiRowStarts) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pWidthInSbsMinus1) as usize - ptr as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(pWidthInSbsMinus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pHeightInSbsMinus1) as usize - ptr as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1TileInfo), - "::", - stringify!(pHeightInSbsMinus1) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1TileInfo"][::core::mem::size_of::() - 48usize]; + ["Alignment of StdVideoAV1TileInfo"][::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoAV1TileInfo::flags"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, flags) - 0usize]; + ["Offset of field: StdVideoAV1TileInfo::TileCols"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, TileCols) - 4usize]; + ["Offset of field: StdVideoAV1TileInfo::TileRows"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, TileRows) - 5usize]; + ["Offset of field: StdVideoAV1TileInfo::context_update_tile_id"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, context_update_tile_id) - 6usize]; + ["Offset of field: StdVideoAV1TileInfo::tile_size_bytes_minus_1"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, tile_size_bytes_minus_1) - 8usize]; + ["Offset of field: StdVideoAV1TileInfo::reserved1"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, reserved1) - 9usize]; + ["Offset of field: StdVideoAV1TileInfo::pMiColStarts"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, pMiColStarts) - 16usize]; + ["Offset of field: StdVideoAV1TileInfo::pMiRowStarts"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, pMiRowStarts) - 24usize]; + ["Offset of field: StdVideoAV1TileInfo::pWidthInSbsMinus1"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, pWidthInSbsMinus1) - 32usize]; + ["Offset of field: StdVideoAV1TileInfo::pHeightInSbsMinus1"] + [::core::mem::offset_of!(StdVideoAV1TileInfo, pHeightInSbsMinus1) - 40usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoAV1CDEF { @@ -7750,184 +5018,66 @@ pub struct StdVideoAV1CDEF { pub cdef_uv_pri_strength: [u8; 8usize], pub cdef_uv_sec_strength: [u8; 8usize], } -#[test] -fn bindgen_test_layout_StdVideoAV1CDEF() { - const UNINIT: ::core::mem::MaybeUninit = ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 34usize, - concat!("Size of: ", stringify!(StdVideoAV1CDEF)) - ); - assert_eq!( - ::core::mem::align_of::(), - 1usize, - concat!("Alignment of ", stringify!(StdVideoAV1CDEF)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cdef_damping_minus_3) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1CDEF), - "::", - stringify!(cdef_damping_minus_3) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cdef_bits) as usize - ptr as usize }, - 1usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1CDEF), - "::", - stringify!(cdef_bits) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cdef_y_pri_strength) as usize - ptr as usize }, - 2usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1CDEF), - "::", - stringify!(cdef_y_pri_strength) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cdef_y_sec_strength) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1CDEF), - "::", - stringify!(cdef_y_sec_strength) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cdef_uv_pri_strength) as usize - ptr as usize }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1CDEF), - "::", - stringify!(cdef_uv_pri_strength) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cdef_uv_sec_strength) as usize - ptr as usize }, - 26usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1CDEF), - "::", - stringify!(cdef_uv_sec_strength) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1CDEF"][::core::mem::size_of::() - 34usize]; + ["Alignment of StdVideoAV1CDEF"][::core::mem::align_of::() - 1usize]; + ["Offset of field: StdVideoAV1CDEF::cdef_damping_minus_3"] + [::core::mem::offset_of!(StdVideoAV1CDEF, cdef_damping_minus_3) - 0usize]; + ["Offset of field: StdVideoAV1CDEF::cdef_bits"] + [::core::mem::offset_of!(StdVideoAV1CDEF, cdef_bits) - 1usize]; + ["Offset of field: StdVideoAV1CDEF::cdef_y_pri_strength"] + [::core::mem::offset_of!(StdVideoAV1CDEF, cdef_y_pri_strength) - 2usize]; + ["Offset of field: StdVideoAV1CDEF::cdef_y_sec_strength"] + [::core::mem::offset_of!(StdVideoAV1CDEF, cdef_y_sec_strength) - 10usize]; + ["Offset of field: StdVideoAV1CDEF::cdef_uv_pri_strength"] + [::core::mem::offset_of!(StdVideoAV1CDEF, cdef_uv_pri_strength) - 18usize]; + ["Offset of field: StdVideoAV1CDEF::cdef_uv_sec_strength"] + [::core::mem::offset_of!(StdVideoAV1CDEF, cdef_uv_sec_strength) - 26usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoAV1LoopRestoration { pub FrameRestorationType: [StdVideoAV1FrameRestorationType; 3usize], pub LoopRestorationSize: [u16; 3usize], } -#[test] -fn bindgen_test_layout_StdVideoAV1LoopRestoration() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 20usize, - concat!("Size of: ", stringify!(StdVideoAV1LoopRestoration)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1LoopRestoration)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).FrameRestorationType) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1LoopRestoration), - "::", - stringify!(FrameRestorationType) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).LoopRestorationSize) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1LoopRestoration), - "::", - stringify!(LoopRestorationSize) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1LoopRestoration"] + [::core::mem::size_of::() - 20usize]; + ["Alignment of StdVideoAV1LoopRestoration"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoAV1LoopRestoration::FrameRestorationType"] + [::core::mem::offset_of!(StdVideoAV1LoopRestoration, FrameRestorationType) - 0usize]; + ["Offset of field: StdVideoAV1LoopRestoration::LoopRestorationSize"] + [::core::mem::offset_of!(StdVideoAV1LoopRestoration, LoopRestorationSize) - 12usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoAV1GlobalMotion { pub GmType: [u8; 8usize], pub gm_params: [[i32; 6usize]; 8usize], } -#[test] -fn bindgen_test_layout_StdVideoAV1GlobalMotion() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 200usize, - concat!("Size of: ", stringify!(StdVideoAV1GlobalMotion)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1GlobalMotion)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).GmType) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1GlobalMotion), - "::", - stringify!(GmType) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).gm_params) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1GlobalMotion), - "::", - stringify!(gm_params) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1GlobalMotion"] + [::core::mem::size_of::() - 200usize]; + ["Alignment of StdVideoAV1GlobalMotion"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoAV1GlobalMotion::GmType"] + [::core::mem::offset_of!(StdVideoAV1GlobalMotion, GmType) - 0usize]; + ["Offset of field: StdVideoAV1GlobalMotion::gm_params"] + [::core::mem::offset_of!(StdVideoAV1GlobalMotion, gm_params) - 8usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoAV1FilmGrainFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoAV1FilmGrainFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoAV1FilmGrainFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1FilmGrainFlags)) - ); -} +const _: () = { + ["Size of StdVideoAV1FilmGrainFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoAV1FilmGrainFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoAV1FilmGrainFlags { #[inline] pub fn chroma_scaling_from_luma(&self) -> u32 { @@ -8047,272 +5197,60 @@ pub struct StdVideoAV1FilmGrain { pub cr_luma_mult: u8, pub cr_offset: u16, } -#[test] -fn bindgen_test_layout_StdVideoAV1FilmGrain() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 164usize, - concat!("Size of: ", stringify!(StdVideoAV1FilmGrain)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1FilmGrain)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).grain_scaling_minus_8) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(grain_scaling_minus_8) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ar_coeff_lag) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(ar_coeff_lag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ar_coeff_shift_minus_6) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(ar_coeff_shift_minus_6) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).grain_scale_shift) as usize - ptr as usize }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(grain_scale_shift) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).grain_seed) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(grain_seed) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).film_grain_params_ref_idx) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(film_grain_params_ref_idx) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_y_points) as usize - ptr as usize }, - 11usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(num_y_points) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).point_y_value) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(point_y_value) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).point_y_scaling) as usize - ptr as usize }, - 26usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(point_y_scaling) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_cb_points) as usize - ptr as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(num_cb_points) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).point_cb_value) as usize - ptr as usize }, - 41usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(point_cb_value) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).point_cb_scaling) as usize - ptr as usize }, - 51usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(point_cb_scaling) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_cr_points) as usize - ptr as usize }, - 61usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(num_cr_points) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).point_cr_value) as usize - ptr as usize }, - 62usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(point_cr_value) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).point_cr_scaling) as usize - ptr as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(point_cr_scaling) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ar_coeffs_y_plus_128) as usize - ptr as usize }, - 82usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(ar_coeffs_y_plus_128) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ar_coeffs_cb_plus_128) as usize - ptr as usize }, - 106usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(ar_coeffs_cb_plus_128) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).ar_coeffs_cr_plus_128) as usize - ptr as usize }, - 131usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(ar_coeffs_cr_plus_128) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cb_mult) as usize - ptr as usize }, - 156usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(cb_mult) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cb_luma_mult) as usize - ptr as usize }, - 157usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(cb_luma_mult) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cb_offset) as usize - ptr as usize }, - 158usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(cb_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cr_mult) as usize - ptr as usize }, - 160usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(cr_mult) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cr_luma_mult) as usize - ptr as usize }, - 161usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(cr_luma_mult) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cr_offset) as usize - ptr as usize }, - 162usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1FilmGrain), - "::", - stringify!(cr_offset) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1FilmGrain"][::core::mem::size_of::() - 164usize]; + ["Alignment of StdVideoAV1FilmGrain"][::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoAV1FilmGrain::flags"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, flags) - 0usize]; + ["Offset of field: StdVideoAV1FilmGrain::grain_scaling_minus_8"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, grain_scaling_minus_8) - 4usize]; + ["Offset of field: StdVideoAV1FilmGrain::ar_coeff_lag"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, ar_coeff_lag) - 5usize]; + ["Offset of field: StdVideoAV1FilmGrain::ar_coeff_shift_minus_6"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, ar_coeff_shift_minus_6) - 6usize]; + ["Offset of field: StdVideoAV1FilmGrain::grain_scale_shift"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, grain_scale_shift) - 7usize]; + ["Offset of field: StdVideoAV1FilmGrain::grain_seed"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, grain_seed) - 8usize]; + ["Offset of field: StdVideoAV1FilmGrain::film_grain_params_ref_idx"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, film_grain_params_ref_idx) - 10usize]; + ["Offset of field: StdVideoAV1FilmGrain::num_y_points"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, num_y_points) - 11usize]; + ["Offset of field: StdVideoAV1FilmGrain::point_y_value"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, point_y_value) - 12usize]; + ["Offset of field: StdVideoAV1FilmGrain::point_y_scaling"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, point_y_scaling) - 26usize]; + ["Offset of field: StdVideoAV1FilmGrain::num_cb_points"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, num_cb_points) - 40usize]; + ["Offset of field: StdVideoAV1FilmGrain::point_cb_value"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, point_cb_value) - 41usize]; + ["Offset of field: StdVideoAV1FilmGrain::point_cb_scaling"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, point_cb_scaling) - 51usize]; + ["Offset of field: StdVideoAV1FilmGrain::num_cr_points"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, num_cr_points) - 61usize]; + ["Offset of field: StdVideoAV1FilmGrain::point_cr_value"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, point_cr_value) - 62usize]; + ["Offset of field: StdVideoAV1FilmGrain::point_cr_scaling"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, point_cr_scaling) - 72usize]; + ["Offset of field: StdVideoAV1FilmGrain::ar_coeffs_y_plus_128"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, ar_coeffs_y_plus_128) - 82usize]; + ["Offset of field: StdVideoAV1FilmGrain::ar_coeffs_cb_plus_128"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, ar_coeffs_cb_plus_128) - 106usize]; + ["Offset of field: StdVideoAV1FilmGrain::ar_coeffs_cr_plus_128"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, ar_coeffs_cr_plus_128) - 131usize]; + ["Offset of field: StdVideoAV1FilmGrain::cb_mult"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, cb_mult) - 156usize]; + ["Offset of field: StdVideoAV1FilmGrain::cb_luma_mult"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, cb_luma_mult) - 157usize]; + ["Offset of field: StdVideoAV1FilmGrain::cb_offset"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, cb_offset) - 158usize]; + ["Offset of field: StdVideoAV1FilmGrain::cr_mult"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, cr_mult) - 160usize]; + ["Offset of field: StdVideoAV1FilmGrain::cr_luma_mult"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, cr_luma_mult) - 161usize]; + ["Offset of field: StdVideoAV1FilmGrain::cr_offset"] + [::core::mem::offset_of!(StdVideoAV1FilmGrain, cr_offset) - 162usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -8320,19 +5258,12 @@ pub struct StdVideoAV1SequenceHeaderFlags { pub _bitfield_align_1: [u16; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoAV1SequenceHeaderFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoAV1SequenceHeaderFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoAV1SequenceHeaderFlags)) - ); -} +const _: () = { + ["Size of StdVideoAV1SequenceHeaderFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoAV1SequenceHeaderFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoAV1SequenceHeaderFlags { #[inline] pub fn still_picture(&self) -> u32 { @@ -8688,168 +5619,46 @@ pub struct StdVideoAV1SequenceHeader { pub pColorConfig: *const StdVideoAV1ColorConfig, pub pTimingInfo: *const StdVideoAV1TimingInfo, } -#[test] -fn bindgen_test_layout_StdVideoAV1SequenceHeader() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 40usize, - concat!("Size of: ", stringify!(StdVideoAV1SequenceHeader)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoAV1SequenceHeader)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).seq_profile) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(seq_profile) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_width_bits_minus_1) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(frame_width_bits_minus_1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_height_bits_minus_1) as usize - ptr as usize }, - 9usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(frame_height_bits_minus_1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).max_frame_width_minus_1) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(max_frame_width_minus_1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).max_frame_height_minus_1) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(max_frame_height_minus_1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).delta_frame_id_length_minus_2) as usize - ptr as usize - }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(delta_frame_id_length_minus_2) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).additional_frame_id_length_minus_1) as usize - ptr as usize - }, - 15usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(additional_frame_id_length_minus_1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).order_hint_bits_minus_1) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(order_hint_bits_minus_1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).seq_force_integer_mv) as usize - ptr as usize }, - 17usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(seq_force_integer_mv) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).seq_force_screen_content_tools) as usize - ptr as usize - }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(seq_force_screen_content_tools) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 19usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pColorConfig) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(pColorConfig) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pTimingInfo) as usize - ptr as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoAV1SequenceHeader), - "::", - stringify!(pTimingInfo) - ) - ); -} +const _: () = { + ["Size of StdVideoAV1SequenceHeader"] + [::core::mem::size_of::() - 40usize]; + ["Alignment of StdVideoAV1SequenceHeader"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoAV1SequenceHeader::flags"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, flags) - 0usize]; + ["Offset of field: StdVideoAV1SequenceHeader::seq_profile"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, seq_profile) - 4usize]; + ["Offset of field: StdVideoAV1SequenceHeader::frame_width_bits_minus_1"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, frame_width_bits_minus_1) - 8usize]; + ["Offset of field: StdVideoAV1SequenceHeader::frame_height_bits_minus_1"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, frame_height_bits_minus_1) - 9usize]; + ["Offset of field: StdVideoAV1SequenceHeader::max_frame_width_minus_1"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, max_frame_width_minus_1) - 10usize]; + ["Offset of field: StdVideoAV1SequenceHeader::max_frame_height_minus_1"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, max_frame_height_minus_1) - 12usize]; + ["Offset of field: StdVideoAV1SequenceHeader::delta_frame_id_length_minus_2"][::core::mem::offset_of!( + StdVideoAV1SequenceHeader, + delta_frame_id_length_minus_2 + ) - 14usize]; + ["Offset of field: StdVideoAV1SequenceHeader::additional_frame_id_length_minus_1"][::core::mem::offset_of!( + StdVideoAV1SequenceHeader, + additional_frame_id_length_minus_1 + ) - 15usize]; + ["Offset of field: StdVideoAV1SequenceHeader::order_hint_bits_minus_1"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, order_hint_bits_minus_1) - 16usize]; + ["Offset of field: StdVideoAV1SequenceHeader::seq_force_integer_mv"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, seq_force_integer_mv) - 17usize]; + ["Offset of field: StdVideoAV1SequenceHeader::seq_force_screen_content_tools"][::core::mem::offset_of!( + StdVideoAV1SequenceHeader, + seq_force_screen_content_tools + ) - 18usize]; + ["Offset of field: StdVideoAV1SequenceHeader::reserved1"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, reserved1) - 19usize]; + ["Offset of field: StdVideoAV1SequenceHeader::pColorConfig"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, pColorConfig) - 24usize]; + ["Offset of field: StdVideoAV1SequenceHeader::pTimingInfo"] + [::core::mem::offset_of!(StdVideoAV1SequenceHeader, pTimingInfo) - 32usize]; +}; #[repr(C)] #[repr(align(4))] #[derive(Debug, Copy, Clone)] @@ -8857,22 +5666,12 @@ pub struct StdVideoDecodeAV1PictureInfoFlags { pub _bitfield_align_1: [u8; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoDecodeAV1PictureInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoDecodeAV1PictureInfoFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoDecodeAV1PictureInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeAV1PictureInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoDecodeAV1PictureInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoDecodeAV1PictureInfoFlags { #[inline] pub fn error_resilient_mode(&self) -> u32 { @@ -9400,284 +6199,72 @@ pub struct StdVideoDecodeAV1PictureInfo { pub pGlobalMotion: *const StdVideoAV1GlobalMotion, pub pFilmGrain: *const StdVideoAV1FilmGrain, } -#[test] -fn bindgen_test_layout_StdVideoDecodeAV1PictureInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 136usize, - concat!("Size of: ", stringify!(StdVideoDecodeAV1PictureInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoDecodeAV1PictureInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_type) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(frame_type) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).current_frame_id) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(current_frame_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).OrderHint) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(OrderHint) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).primary_ref_frame) as usize - ptr as usize }, - 13usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(primary_ref_frame) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).refresh_frame_flags) as usize - ptr as usize }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(refresh_frame_flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 15usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).interpolation_filter) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(interpolation_filter) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).TxMode) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(TxMode) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_q_res) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(delta_q_res) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_lf_res) as usize - ptr as usize }, - 25usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(delta_lf_res) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).SkipModeFrame) as usize - ptr as usize }, - 26usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(SkipModeFrame) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).coded_denom) as usize - ptr as usize }, - 28usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(coded_denom) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved2) as usize - ptr as usize }, - 29usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(reserved2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).OrderHints) as usize - ptr as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(OrderHints) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).expectedFrameId) as usize - ptr as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(expectedFrameId) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pTileInfo) as usize - ptr as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(pTileInfo) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pQuantization) as usize - ptr as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(pQuantization) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pSegmentation) as usize - ptr as usize }, - 88usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(pSegmentation) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pLoopFilter) as usize - ptr as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(pLoopFilter) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pCDEF) as usize - ptr as usize }, - 104usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(pCDEF) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pLoopRestoration) as usize - ptr as usize }, - 112usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(pLoopRestoration) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pGlobalMotion) as usize - ptr as usize }, - 120usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(pGlobalMotion) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pFilmGrain) as usize - ptr as usize }, - 128usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1PictureInfo), - "::", - stringify!(pFilmGrain) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeAV1PictureInfo"] + [::core::mem::size_of::() - 136usize]; + ["Alignment of StdVideoDecodeAV1PictureInfo"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::flags"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, flags) - 0usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::frame_type"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, frame_type) - 4usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::current_frame_id"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, current_frame_id) - 8usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::OrderHint"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, OrderHint) - 12usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::primary_ref_frame"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, primary_ref_frame) - 13usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::refresh_frame_flags"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, refresh_frame_flags) - 14usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::reserved1"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, reserved1) - 15usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::interpolation_filter"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, interpolation_filter) - 16usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::TxMode"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, TxMode) - 20usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::delta_q_res"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, delta_q_res) - 24usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::delta_lf_res"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, delta_lf_res) - 25usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::SkipModeFrame"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, SkipModeFrame) - 26usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::coded_denom"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, coded_denom) - 28usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::reserved2"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, reserved2) - 29usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::OrderHints"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, OrderHints) - 32usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::expectedFrameId"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, expectedFrameId) - 40usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::pTileInfo"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, pTileInfo) - 72usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::pQuantization"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, pQuantization) - 80usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::pSegmentation"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, pSegmentation) - 88usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::pLoopFilter"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, pLoopFilter) - 96usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::pCDEF"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, pCDEF) - 104usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::pLoopRestoration"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, pLoopRestoration) - 112usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::pGlobalMotion"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, pGlobalMotion) - 120usize]; + ["Offset of field: StdVideoDecodeAV1PictureInfo::pFilmGrain"] + [::core::mem::offset_of!(StdVideoDecodeAV1PictureInfo, pFilmGrain) - 128usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoDecodeAV1ReferenceInfoFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoDecodeAV1ReferenceInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoDecodeAV1ReferenceInfoFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoDecodeAV1ReferenceInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeAV1ReferenceInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoDecodeAV1ReferenceInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoDecodeAV1ReferenceInfoFlags { #[inline] pub fn disable_frame_end_update_cdf(&self) -> u32 { @@ -9744,72 +6331,22 @@ pub struct StdVideoDecodeAV1ReferenceInfo { pub OrderHint: u8, pub SavedOrderHints: [u8; 8usize], } -#[test] -fn bindgen_test_layout_StdVideoDecodeAV1ReferenceInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(StdVideoDecodeAV1ReferenceInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoDecodeAV1ReferenceInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1ReferenceInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_type) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1ReferenceInfo), - "::", - stringify!(frame_type) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).RefFrameSignBias) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1ReferenceInfo), - "::", - stringify!(RefFrameSignBias) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).OrderHint) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1ReferenceInfo), - "::", - stringify!(OrderHint) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).SavedOrderHints) as usize - ptr as usize }, - 7usize, - concat!( - "Offset of field: ", - stringify!(StdVideoDecodeAV1ReferenceInfo), - "::", - stringify!(SavedOrderHints) - ) - ); -} +const _: () = { + ["Size of StdVideoDecodeAV1ReferenceInfo"] + [::core::mem::size_of::() - 16usize]; + ["Alignment of StdVideoDecodeAV1ReferenceInfo"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoDecodeAV1ReferenceInfo::flags"] + [::core::mem::offset_of!(StdVideoDecodeAV1ReferenceInfo, flags) - 0usize]; + ["Offset of field: StdVideoDecodeAV1ReferenceInfo::frame_type"] + [::core::mem::offset_of!(StdVideoDecodeAV1ReferenceInfo, frame_type) - 4usize]; + ["Offset of field: StdVideoDecodeAV1ReferenceInfo::RefFrameSignBias"] + [::core::mem::offset_of!(StdVideoDecodeAV1ReferenceInfo, RefFrameSignBias) - 5usize]; + ["Offset of field: StdVideoDecodeAV1ReferenceInfo::OrderHint"] + [::core::mem::offset_of!(StdVideoDecodeAV1ReferenceInfo, OrderHint) - 6usize]; + ["Offset of field: StdVideoDecodeAV1ReferenceInfo::SavedOrderHints"] + [::core::mem::offset_of!(StdVideoDecodeAV1ReferenceInfo, SavedOrderHints) - 7usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH264WeightTableFlags { @@ -9818,65 +6355,24 @@ pub struct StdVideoEncodeH264WeightTableFlags { pub luma_weight_l1_flag: u32, pub chroma_weight_l1_flag: u32, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264WeightTableFlags() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(StdVideoEncodeH264WeightTableFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH264WeightTableFlags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_weight_l0_flag) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTableFlags), - "::", - stringify!(luma_weight_l0_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_weight_l0_flag) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTableFlags), - "::", - stringify!(chroma_weight_l0_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_weight_l1_flag) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTableFlags), - "::", - stringify!(luma_weight_l1_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_weight_l1_flag) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTableFlags), - "::", - stringify!(chroma_weight_l1_flag) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264WeightTableFlags"] + [::core::mem::size_of::() - 16usize]; + ["Alignment of StdVideoEncodeH264WeightTableFlags"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoEncodeH264WeightTableFlags::luma_weight_l0_flag"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTableFlags, luma_weight_l0_flag) - 0usize]; + ["Offset of field: StdVideoEncodeH264WeightTableFlags::chroma_weight_l0_flag"][::core::mem::offset_of!( + StdVideoEncodeH264WeightTableFlags, + chroma_weight_l0_flag + ) - 4usize]; + ["Offset of field: StdVideoEncodeH264WeightTableFlags::luma_weight_l1_flag"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTableFlags, luma_weight_l1_flag) - 8usize]; + ["Offset of field: StdVideoEncodeH264WeightTableFlags::chroma_weight_l1_flag"][::core::mem::offset_of!( + StdVideoEncodeH264WeightTableFlags, + chroma_weight_l1_flag + ) - 12usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH264WeightTable { @@ -9892,154 +6388,48 @@ pub struct StdVideoEncodeH264WeightTable { pub chroma_weight_l1: [[i8; 2usize]; 32usize], pub chroma_offset_l1: [[i8; 2usize]; 32usize], } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264WeightTable() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 404usize, - concat!("Size of: ", stringify!(StdVideoEncodeH264WeightTable)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoEncodeH264WeightTable)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_log2_weight_denom) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(luma_log2_weight_denom) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_log2_weight_denom) as usize - ptr as usize }, - 17usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(chroma_log2_weight_denom) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_weight_l0) as usize - ptr as usize }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(luma_weight_l0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_offset_l0) as usize - ptr as usize }, - 50usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(luma_offset_l0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_weight_l0) as usize - ptr as usize }, - 82usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(chroma_weight_l0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_offset_l0) as usize - ptr as usize }, - 146usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(chroma_offset_l0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_weight_l1) as usize - ptr as usize }, - 210usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(luma_weight_l1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_offset_l1) as usize - ptr as usize }, - 242usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(luma_offset_l1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_weight_l1) as usize - ptr as usize }, - 274usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(chroma_weight_l1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_offset_l1) as usize - ptr as usize }, - 338usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264WeightTable), - "::", - stringify!(chroma_offset_l1) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264WeightTable"] + [::core::mem::size_of::() - 404usize]; + ["Alignment of StdVideoEncodeH264WeightTable"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::flags"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::luma_log2_weight_denom"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, luma_log2_weight_denom) - 16usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::chroma_log2_weight_denom"][::core::mem::offset_of!( + StdVideoEncodeH264WeightTable, + chroma_log2_weight_denom + ) - 17usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::luma_weight_l0"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, luma_weight_l0) - 18usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::luma_offset_l0"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, luma_offset_l0) - 50usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::chroma_weight_l0"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, chroma_weight_l0) - 82usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::chroma_offset_l0"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, chroma_offset_l0) - 146usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::luma_weight_l1"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, luma_weight_l1) - 210usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::luma_offset_l1"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, luma_offset_l1) - 242usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::chroma_weight_l1"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, chroma_weight_l1) - 274usize]; + ["Offset of field: StdVideoEncodeH264WeightTable::chroma_offset_l1"] + [::core::mem::offset_of!(StdVideoEncodeH264WeightTable, chroma_offset_l1) - 338usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH264SliceHeaderFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264SliceHeaderFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoEncodeH264SliceHeaderFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH264SliceHeaderFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264SliceHeaderFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoEncodeH264SliceHeaderFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoEncodeH264SliceHeaderFlags { #[inline] pub fn direct_spatial_mv_pred_flag(&self) -> u32 { @@ -10104,22 +6494,12 @@ pub struct StdVideoEncodeH264PictureInfoFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264PictureInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoEncodeH264PictureInfoFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH264PictureInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264PictureInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoEncodeH264PictureInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoEncodeH264PictureInfoFlags { #[inline] pub fn IdrPicFlag(&self) -> u32 { @@ -10233,25 +6613,12 @@ pub struct StdVideoEncodeH264ReferenceInfoFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264ReferenceInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!( - "Size of: ", - stringify!(StdVideoEncodeH264ReferenceInfoFlags) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH264ReferenceInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264ReferenceInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoEncodeH264ReferenceInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoEncodeH264ReferenceInfoFlags { #[inline] pub fn used_for_long_term_reference(&self) -> u32 { @@ -10299,25 +6666,12 @@ pub struct StdVideoEncodeH264ReferenceListsInfoFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264ReferenceListsInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!( - "Size of: ", - stringify!(StdVideoEncodeH264ReferenceListsInfoFlags) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH264ReferenceListsInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264ReferenceListsInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoEncodeH264ReferenceListsInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoEncodeH264ReferenceListsInfoFlags { #[inline] pub fn ref_pic_list_modification_flag_l0(&self) -> u32 { @@ -10383,57 +6737,23 @@ pub struct StdVideoEncodeH264RefListModEntry { pub abs_diff_pic_num_minus1: u16, pub long_term_pic_num: u16, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264RefListModEntry() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(StdVideoEncodeH264RefListModEntry)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH264RefListModEntry) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).modification_of_pic_nums_idc) as usize - ptr as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264RefListModEntry), - "::", - stringify!(modification_of_pic_nums_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).abs_diff_pic_num_minus1) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264RefListModEntry), - "::", - stringify!(abs_diff_pic_num_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).long_term_pic_num) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264RefListModEntry), - "::", - stringify!(long_term_pic_num) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264RefListModEntry"] + [::core::mem::size_of::() - 8usize]; + ["Alignment of StdVideoEncodeH264RefListModEntry"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoEncodeH264RefListModEntry::modification_of_pic_nums_idc"][::core::mem::offset_of!( + StdVideoEncodeH264RefListModEntry, + modification_of_pic_nums_idc + ) + - 0usize]; + ["Offset of field: StdVideoEncodeH264RefListModEntry::abs_diff_pic_num_minus1"][::core::mem::offset_of!( + StdVideoEncodeH264RefListModEntry, + abs_diff_pic_num_minus1 + ) - 4usize]; + ["Offset of field: StdVideoEncodeH264RefListModEntry::long_term_pic_num"] + [::core::mem::offset_of!(StdVideoEncodeH264RefListModEntry, long_term_pic_num) - 6usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH264RefPicMarkingEntry { @@ -10443,85 +6763,29 @@ pub struct StdVideoEncodeH264RefPicMarkingEntry { pub long_term_frame_idx: u16, pub max_long_term_frame_idx_plus1: u16, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264RefPicMarkingEntry() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 12usize, - concat!( - "Size of: ", - stringify!(StdVideoEncodeH264RefPicMarkingEntry) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH264RefPicMarkingEntry) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).memory_management_control_operation) as usize - - ptr as usize - }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264RefPicMarkingEntry), - "::", - stringify!(memory_management_control_operation) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).difference_of_pic_nums_minus1) as usize - ptr as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264RefPicMarkingEntry), - "::", - stringify!(difference_of_pic_nums_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).long_term_pic_num) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264RefPicMarkingEntry), - "::", - stringify!(long_term_pic_num) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).long_term_frame_idx) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264RefPicMarkingEntry), - "::", - stringify!(long_term_frame_idx) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).max_long_term_frame_idx_plus1) as usize - ptr as usize - }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264RefPicMarkingEntry), - "::", - stringify!(max_long_term_frame_idx_plus1) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264RefPicMarkingEntry"] + [::core::mem::size_of::() - 12usize]; + ["Alignment of StdVideoEncodeH264RefPicMarkingEntry"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoEncodeH264RefPicMarkingEntry::memory_management_control_operation"] [:: core :: mem :: offset_of ! (StdVideoEncodeH264RefPicMarkingEntry , memory_management_control_operation) - 0usize] ; + ["Offset of field: StdVideoEncodeH264RefPicMarkingEntry::difference_of_pic_nums_minus1"][::core::mem::offset_of!( + StdVideoEncodeH264RefPicMarkingEntry, + difference_of_pic_nums_minus1 + ) + - 4usize]; + ["Offset of field: StdVideoEncodeH264RefPicMarkingEntry::long_term_pic_num"] + [::core::mem::offset_of!(StdVideoEncodeH264RefPicMarkingEntry, long_term_pic_num) - 6usize]; + ["Offset of field: StdVideoEncodeH264RefPicMarkingEntry::long_term_frame_idx"][::core::mem::offset_of!( + StdVideoEncodeH264RefPicMarkingEntry, + long_term_frame_idx + ) - 8usize]; + ["Offset of field: StdVideoEncodeH264RefPicMarkingEntry::max_long_term_frame_idx_plus1"][::core::mem::offset_of!( + StdVideoEncodeH264RefPicMarkingEntry, + max_long_term_frame_idx_plus1 + ) + - 10usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH264ReferenceListsInfo { @@ -10538,152 +6802,55 @@ pub struct StdVideoEncodeH264ReferenceListsInfo { pub pRefList1ModOperations: *const StdVideoEncodeH264RefListModEntry, pub pRefPicMarkingOperations: *const StdVideoEncodeH264RefPicMarkingEntry, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264ReferenceListsInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 104usize, - concat!( - "Size of: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH264ReferenceListsInfo) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ref_idx_l0_active_minus1) as usize - ptr as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(num_ref_idx_l0_active_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ref_idx_l1_active_minus1) as usize - ptr as usize - }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(num_ref_idx_l1_active_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).RefPicList0) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(RefPicList0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).RefPicList1) as usize - ptr as usize }, - 38usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(RefPicList1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).refList0ModOpCount) as usize - ptr as usize }, - 70usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(refList0ModOpCount) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).refList1ModOpCount) as usize - ptr as usize }, - 71usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(refList1ModOpCount) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).refPicMarkingOpCount) as usize - ptr as usize }, - 72usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(refPicMarkingOpCount) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 73usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pRefList0ModOperations) as usize - ptr as usize }, - 80usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(pRefList0ModOperations) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pRefList1ModOperations) as usize - ptr as usize }, - 88usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(pRefList1ModOperations) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pRefPicMarkingOperations) as usize - ptr as usize }, - 96usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceListsInfo), - "::", - stringify!(pRefPicMarkingOperations) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264ReferenceListsInfo"] + [::core::mem::size_of::() - 104usize]; + ["Alignment of StdVideoEncodeH264ReferenceListsInfo"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::flags"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceListsInfo, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::num_ref_idx_l0_active_minus1"][::core::mem::offset_of!( + StdVideoEncodeH264ReferenceListsInfo, + num_ref_idx_l0_active_minus1 + ) + - 4usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::num_ref_idx_l1_active_minus1"][::core::mem::offset_of!( + StdVideoEncodeH264ReferenceListsInfo, + num_ref_idx_l1_active_minus1 + ) + - 5usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::RefPicList0"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceListsInfo, RefPicList0) - 6usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::RefPicList1"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceListsInfo, RefPicList1) - 38usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::refList0ModOpCount"][::core::mem::offset_of!( + StdVideoEncodeH264ReferenceListsInfo, + refList0ModOpCount + ) - 70usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::refList1ModOpCount"][::core::mem::offset_of!( + StdVideoEncodeH264ReferenceListsInfo, + refList1ModOpCount + ) - 71usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::refPicMarkingOpCount"][::core::mem::offset_of!( + StdVideoEncodeH264ReferenceListsInfo, + refPicMarkingOpCount + ) - 72usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::reserved1"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceListsInfo, reserved1) - 73usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::pRefList0ModOperations"][::core::mem::offset_of!( + StdVideoEncodeH264ReferenceListsInfo, + pRefList0ModOperations + ) - 80usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::pRefList1ModOperations"][::core::mem::offset_of!( + StdVideoEncodeH264ReferenceListsInfo, + pRefList1ModOperations + ) - 88usize]; + ["Offset of field: StdVideoEncodeH264ReferenceListsInfo::pRefPicMarkingOperations"][::core::mem::offset_of!( + StdVideoEncodeH264ReferenceListsInfo, + pRefPicMarkingOperations + ) + - 96usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH264PictureInfo { @@ -10698,122 +6865,32 @@ pub struct StdVideoEncodeH264PictureInfo { pub reserved1: [u8; 3usize], pub pRefLists: *const StdVideoEncodeH264ReferenceListsInfo, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264PictureInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 32usize, - concat!("Size of: ", stringify!(StdVideoEncodeH264PictureInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoEncodeH264PictureInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).seq_parameter_set_id) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(seq_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_parameter_set_id) as usize - ptr as usize }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(pic_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).idr_pic_id) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(idr_pic_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).primary_pic_type) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(primary_pic_type) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).frame_num) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(frame_num) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).PicOrderCnt) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(PicOrderCnt) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).temporal_id) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(temporal_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 21usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pRefLists) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264PictureInfo), - "::", - stringify!(pRefLists) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264PictureInfo"] + [::core::mem::size_of::() - 32usize]; + ["Alignment of StdVideoEncodeH264PictureInfo"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::flags"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::seq_parameter_set_id"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, seq_parameter_set_id) - 4usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::pic_parameter_set_id"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, pic_parameter_set_id) - 5usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::idr_pic_id"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, idr_pic_id) - 6usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::primary_pic_type"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, primary_pic_type) - 8usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::frame_num"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, frame_num) - 12usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::PicOrderCnt"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, PicOrderCnt) - 16usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::temporal_id"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, temporal_id) - 20usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::reserved1"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, reserved1) - 21usize]; + ["Offset of field: StdVideoEncodeH264PictureInfo::pRefLists"] + [::core::mem::offset_of!(StdVideoEncodeH264PictureInfo, pRefLists) - 24usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH264ReferenceInfo { @@ -10825,92 +6902,26 @@ pub struct StdVideoEncodeH264ReferenceInfo { pub long_term_frame_idx: u16, pub temporal_id: u8, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264ReferenceInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 24usize, - concat!("Size of: ", stringify!(StdVideoEncodeH264ReferenceInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoEncodeH264ReferenceInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).primary_pic_type) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceInfo), - "::", - stringify!(primary_pic_type) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).FrameNum) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceInfo), - "::", - stringify!(FrameNum) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).PicOrderCnt) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceInfo), - "::", - stringify!(PicOrderCnt) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).long_term_pic_num) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceInfo), - "::", - stringify!(long_term_pic_num) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).long_term_frame_idx) as usize - ptr as usize }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceInfo), - "::", - stringify!(long_term_frame_idx) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).temporal_id) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264ReferenceInfo), - "::", - stringify!(temporal_id) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264ReferenceInfo"] + [::core::mem::size_of::() - 24usize]; + ["Alignment of StdVideoEncodeH264ReferenceInfo"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoEncodeH264ReferenceInfo::flags"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceInfo, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH264ReferenceInfo::primary_pic_type"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceInfo, primary_pic_type) - 4usize]; + ["Offset of field: StdVideoEncodeH264ReferenceInfo::FrameNum"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceInfo, FrameNum) - 8usize]; + ["Offset of field: StdVideoEncodeH264ReferenceInfo::PicOrderCnt"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceInfo, PicOrderCnt) - 12usize]; + ["Offset of field: StdVideoEncodeH264ReferenceInfo::long_term_pic_num"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceInfo, long_term_pic_num) - 16usize]; + ["Offset of field: StdVideoEncodeH264ReferenceInfo::long_term_frame_idx"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceInfo, long_term_frame_idx) - 18usize]; + ["Offset of field: StdVideoEncodeH264ReferenceInfo::temporal_id"] + [::core::mem::offset_of!(StdVideoEncodeH264ReferenceInfo, temporal_id) - 20usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH264SliceHeader { @@ -10925,124 +6936,36 @@ pub struct StdVideoEncodeH264SliceHeader { pub disable_deblocking_filter_idc: StdVideoH264DisableDeblockingFilterIdc, pub pWeightTable: *const StdVideoEncodeH264WeightTable, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH264SliceHeader() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 32usize, - concat!("Size of: ", stringify!(StdVideoEncodeH264SliceHeader)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoEncodeH264SliceHeader)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).first_mb_in_slice) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(first_mb_in_slice) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_type) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(slice_type) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_alpha_c0_offset_div2) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(slice_alpha_c0_offset_div2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_beta_offset_div2) as usize - ptr as usize }, - 13usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(slice_beta_offset_div2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_qp_delta) as usize - ptr as usize }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(slice_qp_delta) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 15usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).cabac_init_idc) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(cabac_init_idc) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).disable_deblocking_filter_idc) as usize - ptr as usize - }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(disable_deblocking_filter_idc) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pWeightTable) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH264SliceHeader), - "::", - stringify!(pWeightTable) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH264SliceHeader"] + [::core::mem::size_of::() - 32usize]; + ["Alignment of StdVideoEncodeH264SliceHeader"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::flags"] + [::core::mem::offset_of!(StdVideoEncodeH264SliceHeader, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::first_mb_in_slice"] + [::core::mem::offset_of!(StdVideoEncodeH264SliceHeader, first_mb_in_slice) - 4usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::slice_type"] + [::core::mem::offset_of!(StdVideoEncodeH264SliceHeader, slice_type) - 8usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::slice_alpha_c0_offset_div2"][::core::mem::offset_of!( + StdVideoEncodeH264SliceHeader, + slice_alpha_c0_offset_div2 + ) - 12usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::slice_beta_offset_div2"] + [::core::mem::offset_of!(StdVideoEncodeH264SliceHeader, slice_beta_offset_div2) - 13usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::slice_qp_delta"] + [::core::mem::offset_of!(StdVideoEncodeH264SliceHeader, slice_qp_delta) - 14usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::reserved1"] + [::core::mem::offset_of!(StdVideoEncodeH264SliceHeader, reserved1) - 15usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::cabac_init_idc"] + [::core::mem::offset_of!(StdVideoEncodeH264SliceHeader, cabac_init_idc) - 16usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::disable_deblocking_filter_idc"][::core::mem::offset_of!( + StdVideoEncodeH264SliceHeader, + disable_deblocking_filter_idc + ) - 20usize]; + ["Offset of field: StdVideoEncodeH264SliceHeader::pWeightTable"] + [::core::mem::offset_of!(StdVideoEncodeH264SliceHeader, pWeightTable) - 24usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH265WeightTableFlags { @@ -11051,65 +6974,24 @@ pub struct StdVideoEncodeH265WeightTableFlags { pub luma_weight_l1_flag: u16, pub chroma_weight_l1_flag: u16, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265WeightTableFlags() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 8usize, - concat!("Size of: ", stringify!(StdVideoEncodeH265WeightTableFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 2usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH265WeightTableFlags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_weight_l0_flag) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTableFlags), - "::", - stringify!(luma_weight_l0_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_weight_l0_flag) as usize - ptr as usize }, - 2usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTableFlags), - "::", - stringify!(chroma_weight_l0_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_weight_l1_flag) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTableFlags), - "::", - stringify!(luma_weight_l1_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).chroma_weight_l1_flag) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTableFlags), - "::", - stringify!(chroma_weight_l1_flag) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265WeightTableFlags"] + [::core::mem::size_of::() - 8usize]; + ["Alignment of StdVideoEncodeH265WeightTableFlags"] + [::core::mem::align_of::() - 2usize]; + ["Offset of field: StdVideoEncodeH265WeightTableFlags::luma_weight_l0_flag"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTableFlags, luma_weight_l0_flag) - 0usize]; + ["Offset of field: StdVideoEncodeH265WeightTableFlags::chroma_weight_l0_flag"][::core::mem::offset_of!( + StdVideoEncodeH265WeightTableFlags, + chroma_weight_l0_flag + ) - 2usize]; + ["Offset of field: StdVideoEncodeH265WeightTableFlags::luma_weight_l1_flag"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTableFlags, luma_weight_l1_flag) - 4usize]; + ["Offset of field: StdVideoEncodeH265WeightTableFlags::chroma_weight_l1_flag"][::core::mem::offset_of!( + StdVideoEncodeH265WeightTableFlags, + chroma_weight_l1_flag + ) - 6usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH265WeightTable { @@ -11125,159 +7007,48 @@ pub struct StdVideoEncodeH265WeightTable { pub delta_chroma_weight_l1: [[i8; 2usize]; 15usize], pub delta_chroma_offset_l1: [[i8; 2usize]; 15usize], } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265WeightTable() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 190usize, - concat!("Size of: ", stringify!(StdVideoEncodeH265WeightTable)) - ); - assert_eq!( - ::core::mem::align_of::(), - 2usize, - concat!("Alignment of ", stringify!(StdVideoEncodeH265WeightTable)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_log2_weight_denom) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(luma_log2_weight_denom) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).delta_chroma_log2_weight_denom) as usize - ptr as usize - }, - 9usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(delta_chroma_log2_weight_denom) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_luma_weight_l0) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(delta_luma_weight_l0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_offset_l0) as usize - ptr as usize }, - 25usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(luma_offset_l0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_chroma_weight_l0) as usize - ptr as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(delta_chroma_weight_l0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_chroma_offset_l0) as usize - ptr as usize }, - 70usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(delta_chroma_offset_l0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_luma_weight_l1) as usize - ptr as usize }, - 100usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(delta_luma_weight_l1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).luma_offset_l1) as usize - ptr as usize }, - 115usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(luma_offset_l1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_chroma_weight_l1) as usize - ptr as usize }, - 130usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(delta_chroma_weight_l1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_chroma_offset_l1) as usize - ptr as usize }, - 160usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265WeightTable), - "::", - stringify!(delta_chroma_offset_l1) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265WeightTable"] + [::core::mem::size_of::() - 190usize]; + ["Alignment of StdVideoEncodeH265WeightTable"] + [::core::mem::align_of::() - 2usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::flags"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::luma_log2_weight_denom"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, luma_log2_weight_denom) - 8usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::delta_chroma_log2_weight_denom"][::core::mem::offset_of!( + StdVideoEncodeH265WeightTable, + delta_chroma_log2_weight_denom + ) - 9usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::delta_luma_weight_l0"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, delta_luma_weight_l0) - 10usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::luma_offset_l0"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, luma_offset_l0) - 25usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::delta_chroma_weight_l0"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, delta_chroma_weight_l0) - 40usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::delta_chroma_offset_l0"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, delta_chroma_offset_l0) - 70usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::delta_luma_weight_l1"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, delta_luma_weight_l1) - 100usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::luma_offset_l1"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, luma_offset_l1) - 115usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::delta_chroma_weight_l1"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, delta_chroma_weight_l1) - 130usize]; + ["Offset of field: StdVideoEncodeH265WeightTable::delta_chroma_offset_l1"] + [::core::mem::offset_of!(StdVideoEncodeH265WeightTable, delta_chroma_offset_l1) - 160usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH265SliceSegmentHeaderFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265SliceSegmentHeaderFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!( - "Size of: ", - stringify!(StdVideoEncodeH265SliceSegmentHeaderFlags) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH265SliceSegmentHeaderFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265SliceSegmentHeaderFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoEncodeH265SliceSegmentHeaderFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoEncodeH265SliceSegmentHeaderFlags { #[inline] pub fn first_slice_segment_in_pic_flag(&self) -> u32 { @@ -11522,203 +7293,72 @@ pub struct StdVideoEncodeH265SliceSegmentHeader { pub reserved1: u16, pub pWeightTable: *const StdVideoEncodeH265WeightTable, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265SliceSegmentHeader() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 32usize, - concat!( - "Size of: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH265SliceSegmentHeader) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_type) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_type) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_segment_address) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_segment_address) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).collocated_ref_idx) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(collocated_ref_idx) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).MaxNumMergeCand) as usize - ptr as usize }, - 13usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(MaxNumMergeCand) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_cb_qp_offset) as usize - ptr as usize }, - 14usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_cb_qp_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_cr_qp_offset) as usize - ptr as usize }, - 15usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_cr_qp_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_beta_offset_div2) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_beta_offset_div2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_tc_offset_div2) as usize - ptr as usize }, - 17usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_tc_offset_div2) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_act_y_qp_offset) as usize - ptr as usize }, - 18usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_act_y_qp_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_act_cb_qp_offset) as usize - ptr as usize }, - 19usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_act_cb_qp_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_act_cr_qp_offset) as usize - ptr as usize }, - 20usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_act_cr_qp_offset) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).slice_qp_delta) as usize - ptr as usize }, - 21usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(slice_qp_delta) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 22usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pWeightTable) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265SliceSegmentHeader), - "::", - stringify!(pWeightTable) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265SliceSegmentHeader"] + [::core::mem::size_of::() - 32usize]; + ["Alignment of StdVideoEncodeH265SliceSegmentHeader"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::flags"] + [::core::mem::offset_of!(StdVideoEncodeH265SliceSegmentHeader, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_type"] + [::core::mem::offset_of!(StdVideoEncodeH265SliceSegmentHeader, slice_type) - 4usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_segment_address"][::core::mem::offset_of!( + StdVideoEncodeH265SliceSegmentHeader, + slice_segment_address + ) - 8usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::collocated_ref_idx"][::core::mem::offset_of!( + StdVideoEncodeH265SliceSegmentHeader, + collocated_ref_idx + ) - 12usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::MaxNumMergeCand"] + [::core::mem::offset_of!(StdVideoEncodeH265SliceSegmentHeader, MaxNumMergeCand) - 13usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_cb_qp_offset"][::core::mem::offset_of!( + StdVideoEncodeH265SliceSegmentHeader, + slice_cb_qp_offset + ) - 14usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_cr_qp_offset"][::core::mem::offset_of!( + StdVideoEncodeH265SliceSegmentHeader, + slice_cr_qp_offset + ) - 15usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_beta_offset_div2"][::core::mem::offset_of!( + StdVideoEncodeH265SliceSegmentHeader, + slice_beta_offset_div2 + ) - 16usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_tc_offset_div2"][::core::mem::offset_of!( + StdVideoEncodeH265SliceSegmentHeader, + slice_tc_offset_div2 + ) - 17usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_act_y_qp_offset"][::core::mem::offset_of!( + StdVideoEncodeH265SliceSegmentHeader, + slice_act_y_qp_offset + ) - 18usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_act_cb_qp_offset"][::core::mem::offset_of!( + StdVideoEncodeH265SliceSegmentHeader, + slice_act_cb_qp_offset + ) - 19usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_act_cr_qp_offset"][::core::mem::offset_of!( + StdVideoEncodeH265SliceSegmentHeader, + slice_act_cr_qp_offset + ) - 20usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::slice_qp_delta"] + [::core::mem::offset_of!(StdVideoEncodeH265SliceSegmentHeader, slice_qp_delta) - 21usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::reserved1"] + [::core::mem::offset_of!(StdVideoEncodeH265SliceSegmentHeader, reserved1) - 22usize]; + ["Offset of field: StdVideoEncodeH265SliceSegmentHeader::pWeightTable"] + [::core::mem::offset_of!(StdVideoEncodeH265SliceSegmentHeader, pWeightTable) - 24usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH265ReferenceListsInfoFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265ReferenceListsInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!( - "Size of: ", - stringify!(StdVideoEncodeH265ReferenceListsInfoFlags) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH265ReferenceListsInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265ReferenceListsInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoEncodeH265ReferenceListsInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoEncodeH265ReferenceListsInfoFlags { #[inline] pub fn ref_pic_list_modification_flag_l0(&self) -> u32 { @@ -11788,124 +7428,44 @@ pub struct StdVideoEncodeH265ReferenceListsInfo { pub list_entry_l0: [u8; 15usize], pub list_entry_l1: [u8; 15usize], } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265ReferenceListsInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 68usize, - concat!( - "Size of: ", - stringify!(StdVideoEncodeH265ReferenceListsInfo) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH265ReferenceListsInfo) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceListsInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ref_idx_l0_active_minus1) as usize - ptr as usize - }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceListsInfo), - "::", - stringify!(num_ref_idx_l0_active_minus1) - ) - ); - assert_eq!( - unsafe { - ::core::ptr::addr_of!((*ptr).num_ref_idx_l1_active_minus1) as usize - ptr as usize - }, - 5usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceListsInfo), - "::", - stringify!(num_ref_idx_l1_active_minus1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).RefPicList0) as usize - ptr as usize }, - 6usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceListsInfo), - "::", - stringify!(RefPicList0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).RefPicList1) as usize - ptr as usize }, - 21usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceListsInfo), - "::", - stringify!(RefPicList1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).list_entry_l0) as usize - ptr as usize }, - 36usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceListsInfo), - "::", - stringify!(list_entry_l0) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).list_entry_l1) as usize - ptr as usize }, - 51usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceListsInfo), - "::", - stringify!(list_entry_l1) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265ReferenceListsInfo"] + [::core::mem::size_of::() - 68usize]; + ["Alignment of StdVideoEncodeH265ReferenceListsInfo"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoEncodeH265ReferenceListsInfo::flags"] + [::core::mem::offset_of!(StdVideoEncodeH265ReferenceListsInfo, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH265ReferenceListsInfo::num_ref_idx_l0_active_minus1"][::core::mem::offset_of!( + StdVideoEncodeH265ReferenceListsInfo, + num_ref_idx_l0_active_minus1 + ) + - 4usize]; + ["Offset of field: StdVideoEncodeH265ReferenceListsInfo::num_ref_idx_l1_active_minus1"][::core::mem::offset_of!( + StdVideoEncodeH265ReferenceListsInfo, + num_ref_idx_l1_active_minus1 + ) + - 5usize]; + ["Offset of field: StdVideoEncodeH265ReferenceListsInfo::RefPicList0"] + [::core::mem::offset_of!(StdVideoEncodeH265ReferenceListsInfo, RefPicList0) - 6usize]; + ["Offset of field: StdVideoEncodeH265ReferenceListsInfo::RefPicList1"] + [::core::mem::offset_of!(StdVideoEncodeH265ReferenceListsInfo, RefPicList1) - 21usize]; + ["Offset of field: StdVideoEncodeH265ReferenceListsInfo::list_entry_l0"] + [::core::mem::offset_of!(StdVideoEncodeH265ReferenceListsInfo, list_entry_l0) - 36usize]; + ["Offset of field: StdVideoEncodeH265ReferenceListsInfo::list_entry_l1"] + [::core::mem::offset_of!(StdVideoEncodeH265ReferenceListsInfo, list_entry_l1) - 51usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH265PictureInfoFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265PictureInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!("Size of: ", stringify!(StdVideoEncodeH265PictureInfoFlags)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH265PictureInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265PictureInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoEncodeH265PictureInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoEncodeH265PictureInfoFlags { #[inline] pub fn is_reference(&self) -> u32 { @@ -12089,95 +7649,32 @@ pub struct StdVideoEncodeH265LongTermRefPics { pub delta_poc_msb_present_flag: [u8; 48usize], pub delta_poc_msb_cycle_lt: [u8; 48usize], } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265LongTermRefPics() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 148usize, - concat!("Size of: ", stringify!(StdVideoEncodeH265LongTermRefPics)) - ); - assert_eq!( - ::core::mem::align_of::(), - 2usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH265LongTermRefPics) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_long_term_sps) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265LongTermRefPics), - "::", - stringify!(num_long_term_sps) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).num_long_term_pics) as usize - ptr as usize }, - 1usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265LongTermRefPics), - "::", - stringify!(num_long_term_pics) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).lt_idx_sps) as usize - ptr as usize }, - 2usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265LongTermRefPics), - "::", - stringify!(lt_idx_sps) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).poc_lsb_lt) as usize - ptr as usize }, - 34usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265LongTermRefPics), - "::", - stringify!(poc_lsb_lt) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).used_by_curr_pic_lt_flag) as usize - ptr as usize }, - 50usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265LongTermRefPics), - "::", - stringify!(used_by_curr_pic_lt_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_poc_msb_present_flag) as usize - ptr as usize }, - 52usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265LongTermRefPics), - "::", - stringify!(delta_poc_msb_present_flag) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).delta_poc_msb_cycle_lt) as usize - ptr as usize }, - 100usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265LongTermRefPics), - "::", - stringify!(delta_poc_msb_cycle_lt) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265LongTermRefPics"] + [::core::mem::size_of::() - 148usize]; + ["Alignment of StdVideoEncodeH265LongTermRefPics"] + [::core::mem::align_of::() - 2usize]; + ["Offset of field: StdVideoEncodeH265LongTermRefPics::num_long_term_sps"] + [::core::mem::offset_of!(StdVideoEncodeH265LongTermRefPics, num_long_term_sps) - 0usize]; + ["Offset of field: StdVideoEncodeH265LongTermRefPics::num_long_term_pics"] + [::core::mem::offset_of!(StdVideoEncodeH265LongTermRefPics, num_long_term_pics) - 1usize]; + ["Offset of field: StdVideoEncodeH265LongTermRefPics::lt_idx_sps"] + [::core::mem::offset_of!(StdVideoEncodeH265LongTermRefPics, lt_idx_sps) - 2usize]; + ["Offset of field: StdVideoEncodeH265LongTermRefPics::poc_lsb_lt"] + [::core::mem::offset_of!(StdVideoEncodeH265LongTermRefPics, poc_lsb_lt) - 34usize]; + ["Offset of field: StdVideoEncodeH265LongTermRefPics::used_by_curr_pic_lt_flag"][::core::mem::offset_of!( + StdVideoEncodeH265LongTermRefPics, + used_by_curr_pic_lt_flag + ) - 50usize]; + ["Offset of field: StdVideoEncodeH265LongTermRefPics::delta_poc_msb_present_flag"][::core::mem::offset_of!( + StdVideoEncodeH265LongTermRefPics, + delta_poc_msb_present_flag + ) - 52usize]; + ["Offset of field: StdVideoEncodeH265LongTermRefPics::delta_poc_msb_cycle_lt"][::core::mem::offset_of!( + StdVideoEncodeH265LongTermRefPics, + delta_poc_msb_cycle_lt + ) - 100usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH265PictureInfo { @@ -12194,167 +7691,54 @@ pub struct StdVideoEncodeH265PictureInfo { pub pShortTermRefPicSet: *const StdVideoH265ShortTermRefPicSet, pub pLongTermRefPics: *const StdVideoEncodeH265LongTermRefPics, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265PictureInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 48usize, - concat!("Size of: ", stringify!(StdVideoEncodeH265PictureInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 8usize, - concat!("Alignment of ", stringify!(StdVideoEncodeH265PictureInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_type) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(pic_type) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).sps_video_parameter_set_id) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(sps_video_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_seq_parameter_set_id) as usize - ptr as usize }, - 9usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(pps_seq_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pps_pic_parameter_set_id) as usize - ptr as usize }, - 10usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(pps_pic_parameter_set_id) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).short_term_ref_pic_set_idx) as usize - ptr as usize }, - 11usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(short_term_ref_pic_set_idx) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).PicOrderCntVal) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(PicOrderCntVal) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).TemporalId) as usize - ptr as usize }, - 16usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(TemporalId) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).reserved1) as usize - ptr as usize }, - 17usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(reserved1) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pRefLists) as usize - ptr as usize }, - 24usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(pRefLists) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pShortTermRefPicSet) as usize - ptr as usize }, - 32usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(pShortTermRefPicSet) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pLongTermRefPics) as usize - ptr as usize }, - 40usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265PictureInfo), - "::", - stringify!(pLongTermRefPics) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265PictureInfo"] + [::core::mem::size_of::() - 48usize]; + ["Alignment of StdVideoEncodeH265PictureInfo"] + [::core::mem::align_of::() - 8usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::flags"] + [::core::mem::offset_of!(StdVideoEncodeH265PictureInfo, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::pic_type"] + [::core::mem::offset_of!(StdVideoEncodeH265PictureInfo, pic_type) - 4usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::sps_video_parameter_set_id"][::core::mem::offset_of!( + StdVideoEncodeH265PictureInfo, + sps_video_parameter_set_id + ) - 8usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::pps_seq_parameter_set_id"] + [::core::mem::offset_of!(StdVideoEncodeH265PictureInfo, pps_seq_parameter_set_id) - 9usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::pps_pic_parameter_set_id"][::core::mem::offset_of!( + StdVideoEncodeH265PictureInfo, + pps_pic_parameter_set_id + ) - 10usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::short_term_ref_pic_set_idx"][::core::mem::offset_of!( + StdVideoEncodeH265PictureInfo, + short_term_ref_pic_set_idx + ) - 11usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::PicOrderCntVal"] + [::core::mem::offset_of!(StdVideoEncodeH265PictureInfo, PicOrderCntVal) - 12usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::TemporalId"] + [::core::mem::offset_of!(StdVideoEncodeH265PictureInfo, TemporalId) - 16usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::reserved1"] + [::core::mem::offset_of!(StdVideoEncodeH265PictureInfo, reserved1) - 17usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::pRefLists"] + [::core::mem::offset_of!(StdVideoEncodeH265PictureInfo, pRefLists) - 24usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::pShortTermRefPicSet"] + [::core::mem::offset_of!(StdVideoEncodeH265PictureInfo, pShortTermRefPicSet) - 32usize]; + ["Offset of field: StdVideoEncodeH265PictureInfo::pLongTermRefPics"] + [::core::mem::offset_of!(StdVideoEncodeH265PictureInfo, pLongTermRefPics) - 40usize]; +}; #[repr(C)] #[derive(Debug, Copy, Clone)] pub struct StdVideoEncodeH265ReferenceInfoFlags { pub _bitfield_align_1: [u32; 0], pub _bitfield_1: __BindgenBitfieldUnit<[u8; 4usize]>, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265ReferenceInfoFlags() { - assert_eq!( - ::core::mem::size_of::(), - 4usize, - concat!( - "Size of: ", - stringify!(StdVideoEncodeH265ReferenceInfoFlags) - ) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!( - "Alignment of ", - stringify!(StdVideoEncodeH265ReferenceInfoFlags) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265ReferenceInfoFlags"] + [::core::mem::size_of::() - 4usize]; + ["Alignment of StdVideoEncodeH265ReferenceInfoFlags"] + [::core::mem::align_of::() - 4usize]; +}; impl StdVideoEncodeH265ReferenceInfoFlags { #[inline] pub fn used_for_long_term_reference(&self) -> u32 { @@ -12420,59 +7804,17 @@ pub struct StdVideoEncodeH265ReferenceInfo { pub PicOrderCntVal: i32, pub TemporalId: u8, } -#[test] -fn bindgen_test_layout_StdVideoEncodeH265ReferenceInfo() { - const UNINIT: ::core::mem::MaybeUninit = - ::core::mem::MaybeUninit::uninit(); - let ptr = UNINIT.as_ptr(); - assert_eq!( - ::core::mem::size_of::(), - 16usize, - concat!("Size of: ", stringify!(StdVideoEncodeH265ReferenceInfo)) - ); - assert_eq!( - ::core::mem::align_of::(), - 4usize, - concat!("Alignment of ", stringify!(StdVideoEncodeH265ReferenceInfo)) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).flags) as usize - ptr as usize }, - 0usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceInfo), - "::", - stringify!(flags) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).pic_type) as usize - ptr as usize }, - 4usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceInfo), - "::", - stringify!(pic_type) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).PicOrderCntVal) as usize - ptr as usize }, - 8usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceInfo), - "::", - stringify!(PicOrderCntVal) - ) - ); - assert_eq!( - unsafe { ::core::ptr::addr_of!((*ptr).TemporalId) as usize - ptr as usize }, - 12usize, - concat!( - "Offset of field: ", - stringify!(StdVideoEncodeH265ReferenceInfo), - "::", - stringify!(TemporalId) - ) - ); -} +const _: () = { + ["Size of StdVideoEncodeH265ReferenceInfo"] + [::core::mem::size_of::() - 16usize]; + ["Alignment of StdVideoEncodeH265ReferenceInfo"] + [::core::mem::align_of::() - 4usize]; + ["Offset of field: StdVideoEncodeH265ReferenceInfo::flags"] + [::core::mem::offset_of!(StdVideoEncodeH265ReferenceInfo, flags) - 0usize]; + ["Offset of field: StdVideoEncodeH265ReferenceInfo::pic_type"] + [::core::mem::offset_of!(StdVideoEncodeH265ReferenceInfo, pic_type) - 4usize]; + ["Offset of field: StdVideoEncodeH265ReferenceInfo::PicOrderCntVal"] + [::core::mem::offset_of!(StdVideoEncodeH265ReferenceInfo, PicOrderCntVal) - 8usize]; + ["Offset of field: StdVideoEncodeH265ReferenceInfo::TemporalId"] + [::core::mem::offset_of!(StdVideoEncodeH265ReferenceInfo, TemporalId) - 12usize]; +}; diff --git a/generator/Cargo.toml b/generator/Cargo.toml index 286f312d2..3efbb73e3 100644 --- a/generator/Cargo.toml +++ b/generator/Cargo.toml @@ -9,7 +9,7 @@ publish = false # Pin version to have control over how ash/src/vk/native.rs # is generated (there is a CI check that validates that this # file is generated as currently checked in): -bindgen = "=0.69.4" +bindgen = "=0.70.0" heck = "0.5" itertools = "0.13" nom = "7.1"