pub fn yuv422_to_rgb(
planar_image: &YuvPlanarImage<'_, u8>,
rgb: &mut [u8],
rgb_stride: u32,
range: YuvRange,
matrix: YuvStandardMatrix,
) -> Result<(), YuvError>Expand description
Convert YUV 422 planar format to RGB format.
This function takes YUV 422 data with 8-bit precision, and converts it to RGB format with 8-bit per channel precision.
§Arguments
planar_image- Source planar image.rgb- A mutable slice to store the converted RGB data.rgb_stride- The stride (components per row) for the RGB image data.range- The YUV range (limited or full).matrix- The YUV standard matrix (BT.601 or BT.709 or BT.2020 or other).
§Panics
This function panics if the lengths of the planes or the input RGB data are not valid based on the specified width, height, and strides, or if invalid YUV range or matrix is provided.