Convert from YCbCr to RGB
MT, SSE2, Family10h
FwStatus | fwiYCbCrToRGB_8u_C3R | ( | const Fw8u * pSrc, int srcStep, Fw8u * pDst, int dstStep, FwiSize roiSize ); | |
FwStatus | fwiYCbCrToRGB_8u_AC4R | ( | const Fw8u * pSrc, int srcStep, Fw8u * pDst, int dstStep, FwiSize roiSize ); | |
FwStatus | fwiYCbCrToRGB_8u_P3R | ( | const Fw8u * const pSrc[3], int srcStep, Fw8u * const pDst[3], int dstStep, FwiSize roiSize ); | |
FwStatus | fwiYCbCrToRGB_8u_P3C3R | ( | const Fw8u * const pSrc[3], int srcStep, Fw8u * pDst, int dstStep, FwiSize roiSize ); |
dstStep | Destination buffer step size (width of the buffer in bytes). | |
pDst | Pointer to a location in a destination buffer. | |
pDst[3] | Pointer to a location in a three-channel planar destination buffer (array values point to a location in each plane). | |
pSrc | Pointer to a location in a source buffer. | |
pSrc[3] | Pointer to a location in a three-channel planar source buffer (array values point to a location in each plane). | |
roiSize | Specifies the height and width of an ROI. | |
srcStep | Source buffer step size (width of the buffer in bytes). |
These functions step through an ROI in a source buffer, convert the source data from the YCbCr color space to the RGB model, and write the converted data to a destination buffer.
A YUV image (pSrc) declared in the ROI (roiSize) is converted to a gamma-corrected RGB image (pDst).
The following conversion formulas are used:
R = 1.164*(Y-16) + 1.596*(Cr-128) G = 1.164*(Y-16) - 0.392*(Cb-128) - 0.813*(Cr-128) B = 1.164*(Y-16) + 2.017*(Cb-128)