pub type VideoFormat = VSVideoFormat;Aliased Type§
#[repr(C)]pub struct VideoFormat {
pub color_family: VSColorFamily,
pub sample_type: VSSampleType,
pub bits_per_sample: i32,
pub bytes_per_sample: i32,
pub sub_sampling_w: i32,
pub sub_sampling_h: i32,
pub num_planes: i32,
}Fields§
§color_family: VSColorFamilySee [VSColorFamily].
sample_type: VSSampleTypeSee [VSSampleType].
bits_per_sample: i32Number of significant bits.
bytes_per_sample: i32Number of bytes needed for a sample. This is always a power of 2 and the smallest possible that can fit the number of bits used per sample.
sub_sampling_w: i32log2 subsampling factor, applied to second and third plane
sub_sampling_h: i32log2 subsampling factor, applied to second and third plane.
Convenient numbers that can be used like so:
uv_width = y_width >> subSamplingW;num_planes: i32Number of planes, implicit from colorFamily