pub fn yuv_nv24_to_bgr(
bi_planar_image: &YuvBiPlanarImage<'_, u8>,
bgr: &mut [u8],
bgr_stride: u32,
range: YuvRange,
matrix: YuvStandardMatrix,
mode: YuvConversionMode,
) -> Result<(), YuvError>Expand description
Convert YUV NV24 format to BGR format.
This function takes YUV NV24 data with 8-bit precision, and converts it to BGR format with 8-bit per channel precision.
§Arguments
bi_planar_image- Source Bi-Planar image.bgr- A mutable slice to store the converted BGR data.bgr_stride- The stride (components per row) for the BGR 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 BGR data are not valid based on the specified width, height, and strides, or if invalid YUV range or matrix is provided.