pub fn bgr_to_xyz(
src: &[u8],
src_stride: u32,
dst: &mut [f32],
dst_stride: u32,
width: u32,
height: u32,
matrix: &[[f32; 3]; 3],
transfer_function: TransferFunction,
)Expand description
This function converts BGR to XYZ. This is much more effective than naive direct transformation
§Arguments
src- A slice contains BGR datasrc_stride- Bytes per row for src data.width- Image widthheight- Image heightdst- A mutable slice to receive XYZ datadst_stride- Bytes per row for dst datamatrix- Transformation matrix from BGR to XYZ. If you don’t have specific just pickSRGB_TO_XYZ_D65transfer_function- Transfer function from gamma to linear space. If you don’t have specific pickSrgb