# Image Conversion Functions

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_UYVYtoRGB888andScale(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride, uint8\_t \*\_\_restrict dstS2, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstS2Props, uint8\_t \*\_\_restrict dst2, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dst2Props)

    - Converts an 8-bit UYVY image to RGB888 using parameters of [FadasCvtYUV\_UYVYtoRGB()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gafb5786870f940adce24b5cd09e2d3573) and downscales by both sqrt(2) and 2 in dimensions. Both downscaling operations must be done and are not optional. If only one downscaling is needed then use separate functions.

**WARNING:** Obsolete.

- Parameters:

    - - **src** – Input 8-bit UYVY source image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Output RGB888 destination image. **WARNING:** Adequate memory must already be allocated to the image buffer.
- **dstStride** – Stride (bytes) for dst [dst\_stride &gt;= dst\_w \* 3]. If set to 0 before calling, an appropriate value will be assigned. **WARNING:** Must be a multiple of 128.
- **dstS2** – Output RGB888 image downscaled by sqrt(2). **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstS2Props** – Downscaled image (dstS2) properties. **WARNING:** Must be a multiple of 128.
- **dst2** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dst2Props** – Downscaled image (dst2) properties. **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_UYVYtoGray(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Converts an 8-bit UYVY image to grayscale.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Must be a multiple of 128.
- **dst** – Pointer to the output grayscale image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst. **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_VYUYtoGray(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Converts an 8-bit VYUY image to grayscale.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Must be a multiple of 128.
- **dst** – Pointer to the output grayscale image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst. **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_UYVYtoNV12(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dstY, uint32\_t dstYStride, uint8\_t \*\_\_restrict dstUV, uint32\_t dstUVStride)

    - Converts an 8-bit UYVY image to NV12.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Must be a multiple of 128.
- **dstY** – Pointer to the luma (Y) component of the output image. **WARNING:** Must be 128-byte aligned.
- **dstYStride** – Stride (bytes) for the dstY parameter. **WARNING:** Must be a multiple of 128.
- **dstUV** – Pointer to the UY pseudo planes of the output image. **WARNING:** Must be 128-byte aligned.
- **dstUVStride** – Stride (bytes) for the dstUV parameter. **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_VYUYtoNV12(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dstY, uint32\_t dstYStride, uint8\_t \*\_\_restrict dstUV, uint32\_t dstUVStride)

    - Converts an 8-bit VYUY image to NV12.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Must be a multiple of 128.
- **dstY** – Pointer to the luma (Y) component of the output image. **WARNING:** Must be 128-byte aligned.
- **dstYStride** – Stride (bytes) for the dstY parameter. **WARNING:** Must be a multiple of 128.
- **dstUV** – Pointer to the UY pseudo planes of the output image. **WARNING:** Must be 128-byte aligned.
- **dstUVStride** – Stride (bytes) for the dstUV parameter. **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_UYVY10toNV12(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dstY, uint32\_t dstYStride, uint8\_t \*\_\_restrict dstUV, uint32\_t dstUVStride)

    - Converts 10-bit UYVY image to NV12.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dstY** – Pointer to the luma (Y) component of the output image. **WARNING:** Must be 128-byte aligned.
- **dstYStride** – Stride (bytes) for the dstY parameter. **WARNING:** Must be a multiple of 128.
- **dstUV** – Pointer to the UY pseudo planes of the output image. **WARNING:** Must be 128-byte aligned.
- **dstUVStride** – Stride (bytes) for the dstUV parameter. **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_UYVYtoRGB(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Converts an 8-bit UYVY image to RGB888. Using the equations of *The Image Processing Handbook* (Russ and Neal 2015) and dropping the primes for convenience gives:

\[ Y=K\_R R + K\_G G + K\_B B \]

\[ C\_b = 0.5 \left( \frac{B-Y}{1-K\_B} \right) \]

\[ C\_r = 0.5 \left( \frac{R-Y}{1-K\_R} \right) \]

and inverts to:

\[\begin{split} \begin{bmatrix}R\\G\\B\end{bmatrix} = \begin{bmatrix}1 & 0 & 2(1-K\_R)\\1 & -\frac{2( K\_R (1-K\_R)}{K\_G} & -\frac{2( K\_B (1-K\_B)}{K\_G}\\1 & 2(1-K\_B) & 0\end{bmatrix} \begin{bmatrix}Y\\C\_b\\C\_r\end{bmatrix} \end{split}\]

The color conversion parameters follow those from the ITU-R BT.601-7 recommendation of \(K\_R=0.299\), \(K\_B=0.114\), and \(K\_G=0.587\).

\[\begin{split} \begin{bmatrix}R\\G\\B\end{bmatrix} = \begin{bmatrix}1 & 0 & 1.402000\\1 & -0.344136 & -0.714136\\1 & 1.772000 & 0\end{bmatrix} \begin{bmatrix}Y\\C\_b\\C\_r\end{bmatrix} \end{split}\]

The OpenCV equivalent can be:

FadasImgProps_t srcProps = { w, h, 2*w };
    uint32_t dstStride = 3*w;
    
    FadasCvtYUV_UYVYtoYUV_R( uyvyimg, srcProps, yuvimg, dstStride );
    
    for( int r=0; r<h; ++r )
       for( int c = 0; c < w; ++c )
       {
           int idx = 3 * (w * r + c);
           uint8_t u = yuvimg[idx + 1];
           uint8_t v = yuvimg[idx + 2];
           yuvimg[idx + 1] = v;
           yuvimg[idx + 2] = u;
       }
    
    cv::Mat ocvYUVImage( h, w, CV_8UC3, const_cast<uint8_t*>(yuvimg) );
    cv::Mat ocvRGBImage( h, w, CV_8UC3, const_cast<uint8_t*>(rgbimg) );
    cv::cvtColor( ocvYUVImage, ocvRGBImage, cv::COLOR_YCrCb2RGB );
    Copy to clipboard

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst [dstStride &gt;= width \* 3] **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_UYVYtoRGBAndNormi8(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, int8\_t \*dst, uint32\_t dstStride)

    - Same as [FadasCvtYUV\_UYVYtoRGB()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gafb5786870f940adce24b5cd09e2d3573) with the additional step of normalization with int8 output at the end.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dst** – Pointer to the output image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst [dstStride &gt;= width \* 3]

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_UYVYtoRGBAndNormu8(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, uint8\_t \*dst, uint32\_t dstStride)

    - Same as [FadasCvtYUV\_UYVYtoRGB()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gafb5786870f940adce24b5cd09e2d3573) with the additional step of normalization with uint8 output at the end.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dst** – Pointer to the output image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst [dstStride &gt;= width \* 3]

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_VYUYtoRGB(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Converts an 8-bit VYUY image to RGB888. See [FadasCvtYUV\_UYVYtoRGB](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gafb5786870f940adce24b5cd09e2d3573) for more details.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst [dstStride &gt;= width \* 3] **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_UYVY10toRGB(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Converts 10-bit UYVY image to RGB888. The color conversion parameters of [FadasCvtYUV\_UYVYtoRGB()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gafb5786870f940adce24b5cd09e2d3573) are used.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst [dstStride &gt;= width \* 3] **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_UYVYtoYUV(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Converts an 8-bit UYVY image to YUV888.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_VYUYtoYUV(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Converts an 8-bit VYUY image to YUV888.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Y12ToY8(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Converts a 12-bit Y image to 8 - bit Y image.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Must be a multiple of 128.
- **dst** – Pointer to the output grayscale image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst. **WARNING:** Must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Y10ToY8(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Converts a 10-bit Y image to 8 - bit Y image.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride must be a multiple of 128.
- **dst** – Pointer to the output grayscale image. **WARNING:** Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst. **WARNING:** Stride must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleBy2(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstProps)

    - Scale a single-channel image (*e.g*., grayscale) down by two in dimension (four in resolution).

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties. **WARNING:** Stride (bytes) must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY8UV8by2(const [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*\_\_restrict src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*\_\_restrict dst)

    - Scale multiplane image (*e.g*., Y and UV) down by two in dimension (four in resolution).

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY10UV10by2(const [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*\_\_restrict src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*\_\_restrict dst)

    - Scale multiplane image (*e.g*., Y and UV) down by two in dimension (four in resolution).

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Downscale888by2(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstProps)

    - Scale a RGB888 image down by two in dimension (four in resolution).

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties. **WARNING:** Stride (bytes) must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleBySqrt2(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstProps)

    - Scale image down by two in resolution or sqrt(2) in dimensions.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. Stride (bytes) for src. **WARNING:** Must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties **WARNING:** Stride (bytes) must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Downscale888bySqrt2(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstProps)

    - Scale RGB888 image down by two in resolution or sqrt(2) in dimensions.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties. **WARNING:** Stride (bytes) must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Downscale(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) dstProps)

    - Scale image down by 1x to 2x in each dimension and the ratios in height and width need not be the same.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties. **WARNING:** Stride (bytes) must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Downscale888(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*\_\_restrict dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) dstProps)

    - Scale RGB image down by 1x - 2x in each dimension and the ratios in height and width need not be the same.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image width (pixels). **WARNING:** Stride (bytes) must be a multiple of 128.
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties. **WARNING:** Stride (bytes) must be a multiple of 128.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY8UV8(const [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst)

    - Scale multiplane image (*e.g*., Y, UV with 8 bit data) down by 1x - 8x in each dimension and the ratios in height and width need not be the same.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY10UV10(const [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst)

    - Scale multiplane image (*e.g*., Y, UV with 10 bit data in 16 bit carriers) down by 1x to 8x in each dimension. The ratios in height and width need not be the same.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleYUV888AndRGB888(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) dstProps)

    - Scale YUV888 image down by 1x to 8x in each dimension, the ratios in height and width need not be the same, and convert to RGB888.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image width (pixels).
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Input image properties.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleUYVYAndRGB888(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) dstProps)

    - Scale UYVY image down by 1x to 8x in each dimension, the ratios in height and width need not be the same, and convert to RGB888.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Should be 128-bit aligned.
- **srcProps** – Input image properties.
- **dst** – Pointer to the output image. **WARNING:** Adequate memory must already be allocated to the image buffer. **WARNING:** Should be 128-byte aligned.
- **dstProps** – Output image properties.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleYUV888By2AndRGB888(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstProps)

    - Scale YUV888 image down by two in each dimension, the ratios in height and width need not be the same, and convert to RGB888. Color conversion uses the parameters of [FadasCvtYUV\_UYVYtoRGB()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gafb5786870f940adce24b5cd09e2d3573).

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties.
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleUYVYBy2AndRGB888(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstProps)

    - Scale UYVY image down by two in each dimension and convert to RGB888. Color conversion uses the parameters of [FadasCvtYUV\_UYVYtoRGB()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gafb5786870f940adce24b5cd09e2d3573).

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties.
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Input image properties.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleUYVYBy2ToRGB888AndNormi8(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, int8\_t \*dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstProps)

    - Same as [FadasCvtYUV\_DownscaleUYVYBy2AndRGB888()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1ga43ad6ed3bf6aba50911aacbda897198a), with the additional step of normalization with int8 output at the end.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties.
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleUYVYBy2ToRGB888AndNormu8(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, uint8\_t \*dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstProps)

    - Same as [FadasCvtYUV\_DownscaleUYVYBy2AndRGB888()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1ga43ad6ed3bf6aba50911aacbda897198a), with the additional step of normalization with uint8 output at the end.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties.
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleVYUYAndRGB888(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) dstProps)

    - Scale VYUY image down by 1x to 8x in each dimension, the ratios in height and width need not be the same, and convert to RGB888.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Should be 128-bit aligned.
- **srcProps** – Input image properties.
- **dst** – Pointer to the output image. **WARNING:** Adequate memory must already be allocated to the image buffer. **WARNING:** Should be 128-byte aligned.
- **dstProps** – Output image properties.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleVYUYBy2AndRGB888(const uint8\_t \*src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, uint8\_t \*dst, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) \*dstProps)

    - Scale VYUY image down by two in each dimension and convert to RGB888. Color conversion uses parameters of [FadasCvtYUV\_VYUYtoRGB()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1ga74ff417c26a8fdbec948d7fb5a5d795f).

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties.
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstProps** – Output image properties.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Renormalize(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlz, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Scales 8-bit single-channel integer image intensities \((y)\) by subtracting a constant \((s)\), multiplying by another constant \((m)\), and then adding by another constant \((a)\).

\[ y' = m (y - s) + a \]

 Normalization typically occurs using patch-based or a globally measured mean \((s = \mu)\) and standard deviation \((m = 1/\sigma)\). 
\[ y' = (y - \mu)/\sigma \]

 Scaling to a new mean \((\mu')\) and width \((\sigma')\) can be combined into single constants \(m = \sigma'/\sigma\), \(s = \mu\), and \(a = \mu'\). 
\[\begin{split}\begin{eqnarray\*} y' &=& m (y - s) + a \\ &=& (\sigma'/\sigma)(y - \mu) + \mu' \end{eqnarray\*}\end{split}\]

 Because this routine outputs into 8-bit unsigned integers, values should be chosen accordingly. Incoming mean and standard deviation can be measured, however the targeted range and bias might be fixed to the requirements of the next algorithm in the processing pipeline. One possible example is \(\sigma'\approx 32\) and \(\mu'\approx 128\).

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **normlz** – Input normalization parameters. **WARNING:**

    - normlz.sub \((s)\) has a limited valid range of \(-255 \le s \le 255\).
    - normlz.mul \((m)\) has a limited valid range of \(-4 \le m \le 4\).
    - normlz.add \((a)\) has a limited valid range of \(-255 \le a \le 255\).
- **dst** – Pointer to the output image. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst [dstStride &gt;= width].

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Renormalize888(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, uint8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Scales 8-bit three-channel color image intensities \((y\_i)\) by subtracting a constant \((s\_i)\), multiplying by another constant \((m\_i)\), and then adding by another constant \((a\_i)\).

\[ y'\_i = m\_i (y\_i - s\_i) + a\_i \]

 Normalization typically occurs using patch-based or a globally measured mean \((s\_i = \mu\_i)\) and standard deviation \((m\_i = 1/\sigma\_i)\) for each color channel. 
\[ y'\_i = (y\_i - \mu\_i)/\sigma\_i \]

 Scaling to a new mean \((\mu'\_i)\) and width \((\sigma'\_i)\) for each color channel can be combined into single constants \(m\_i = \sigma'\_i/\sigma\_i\), \(s\_i = \mu\_i\), and \(a\_i = \mu'\_i\) for each channel. 
\[\begin{split}\begin{eqnarray\*} y'\_i &=& m\_i (y\_i - s\_i) + a\_i \\ &=& (\sigma'\_i/\sigma\_i)(y\_i - \mu\_i) + \mu'\_i \end{eqnarray\*}\end{split}\]

 Because this routine outputs into 8-bit unsigned integers, values should be chosen accordingly. Incoming mean and standard deviation can be measured, however the targeted range and bias might be fixed to the requirements of the next algorithm in the processing pipeline. One possible example is \(\sigma'\_i\approx 32\) and \(\mu'\_i\approx 128\).

- Parameters:

    - - **src** – Pointer to the input 8-bit three-channel color image intensities (for example, RGB888). **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dst** – Pointer to the output image in RGB888 format. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 128-byte aligned.
- **dstStride** – Stride (bytes) for dst [dstStride &gt;= dst\_w \* 3].

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Renormalize888u8i8(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, int8\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Same as [FadasCvtYUV\_Renormalize888()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1ga27a65425f1502e5a512dc6c92313abed), except that this function outputs to a signed 8-bit image. This output can be used as one layer of a linear-quantized int8 NHWC format.

- Parameters:

    - - **src** – Pointer to the input signed 8-bit three-channel image intensities (for example, HWC). **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dst** – Pointer to the output image in RGB888 INT8 HWC format. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 16-byte aligned.
- **dstStride** – Stride (bytes) for dst [dst\_stride &gt;= dst\_w \* 3 \* sizeof(float16\_t)].

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Renormalize888u8f32(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, [float32\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/typedef_fadas_8h_1a4611b605e45ab401f02cab15c5e38715.html#_CPPv49float32_t) \*\_\_restrict dst, uint32\_t dstStride)

    - Same as [FadasCvtYUV\_Renormalize888()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1ga27a65425f1502e5a512dc6c92313abed) except that this function outputs to a floating-point image of the same HWC layout. This output is appropriate for one layer of a NHWC floating-point format.

- Parameters:

    - - **src** – Pointer to the input 8-bit three-channel color image intensities (for example, RGB888). **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dst** – Pointer to the output image in floating-point HWC format. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 16-byte aligned.
- **dstStride** – Stride (bytes) for dst [dst\_stride &gt;= dst\_w \* 3 \* sizeof(float32\_t)].

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Renormalize888i8f32(const int8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, [float32\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/typedef_fadas_8h_1a4611b605e45ab401f02cab15c5e38715.html#_CPPv49float32_t) \*\_\_restrict dst, uint32\_t dstStride)

    - Same as [FadasCvtYUV\_Renormalize888u8f32()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gaca82a1ea5d5ba9ca51adafe3a725264f) except that input for this function is from int8 instead of uint8. This output is appropriate for one layer of a NHWC floating-point format.

- Parameters:

    - - **src** – Pointer to the input image. **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dst** – Pointer to the output image in floating-point HWC format. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 16-byte aligned.
- **dstStride** – Stride (bytes) for dst [dst\_stride &gt;= dst\_w \* 3 \* sizeof(float16\_t)].

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Renormalize888u8f16(const uint8\_t \*\_\_restrict src, [FadasImgProps\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_img_props__t.html#_CPPv415FadasImgProps_t) srcProps, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, float16\_t \*\_\_restrict dst, uint32\_t dstStride)

    - Same as [FadasCvtYUV\_Renormalize888()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1ga27a65425f1502e5a512dc6c92313abed) except that this function outputs to a half precision floating-point image of the same HWC layout. This output is appropriate for one layer of a NHWC floating-point format.

- Parameters:

    - - **src** – Pointer to the input image **WARNING:** Must be 128-byte aligned.
- **srcProps** – Input image properties. **WARNING:** Stride (bytes) must be a multiple of 128.
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dst** – Pointer to the output image in half precision floating-point HWC format. **WARNING:**

    - Adequate memory must already be allocated to the image buffer.
    - Must be 16-byte aligned.
- **dstStride** – Stride (bytes) for dst [dst\_stride &gt;= dst\_w \* 3 \* sizeof(float16\_t)].

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY8UV8AndRGB888([FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst, [FadasROI\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_r_o_i__t.html#_CPPv410FadasROI_t) \*dstROI)

    - Scale Y8UV8 Image down by 1x to 8x in each dimension and convert image to RGB888.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dstROI** – Region of interest in output image.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY8UV8ToRGB888AndNormi8([FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, [FadasROI\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_r_o_i__t.html#_CPPv410FadasROI_t) \*dstROI)

    - Same as [FadasCvtYUV\_DownscaleY8UV8AndRGB888()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gae7ea6e9e3bcd05e8a2f41d727f61ad78), with the additional step of normalization with int8 output at the end.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dstROI** – Region of interest in output image.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY8UV8ToRGB888AndNormu8([FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, [FadasROI\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_r_o_i__t.html#_CPPv410FadasROI_t) \*dstROI)

    - Same as [FadasCvtYUV\_DownscaleY8UV8AndRGB888()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1gae7ea6e9e3bcd05e8a2f41d727f61ad78), with the additional step of normalization with uint8 output at the end.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dstROI** – Region of interest in output image.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY8UV8By2AndRGB888([FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst, [FadasROI\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_r_o_i__t.html#_CPPv410FadasROI_t) \*dstROI)

    - Scale Y8UV8 Image down by 2 in each dimension and convert image to RGB888.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dstROI** – Region of interest in output image.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY8UV8By2ToRGB888AndNormi8([FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, [FadasROI\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_r_o_i__t.html#_CPPv410FadasROI_t) \*dstROI)

    - Same as [FadasCvtYUV\_DownscaleY8UV8By2AndRGB888()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1ga4538c8423582c8c79a7272909da8cd6a), with the additional step of normalization with int8 output at the end.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dstROI** – Region of interest in output image.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY8UV8By2ToRGB888AndNormu8([FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, [FadasROI\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_r_o_i__t.html#_CPPv410FadasROI_t) \*dstROI)

    - Same as [FadasCvtYUV\_DownscaleY8UV8By2AndRGB888()](https://docs.qualcomm.com/doc/80-63309-1/topic/image-conversion-functions.html#group__cvtyuvh_1ga4538c8423582c8c79a7272909da8cd6a), with the additional step of normalization with uint8 output at the end.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dstROI** – Region of interest in output image.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Y8UV8ToRGB888AndNormi8([FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, [FadasROI\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_r_o_i__t.html#_CPPv410FadasROI_t) \*dstROI)

    - Convert a Y8UV8 image to RGB888 and Normalize to int8.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dstROI** – Region of interest in output image.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Y8UV8ToRGB888AndNormu8([FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzR, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzG, [FadasNormlzParams\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_normlz_params__t.html#_CPPv419FadasNormlzParams_t) normlzB, [FadasROI\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_r_o_i__t.html#_CPPv410FadasROI_t) \*dstROI)

    - Convert a Y8UV8 image to RGB888 and Normalize to uint8.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **normlzR** – Image normalization parameters for red channel. **WARNING:**

    - normlz.sub \((s\_r)\) has a limited valid range of \(-255 \le s\_r \le 255\).
    - normlz.mul \((m\_r)\) has a limited valid range of \(-4 \le m\_r \le 4\).
    - normlz.add \((a\_r)\) has a limited valid range of \(-255 \le a\_r \le 255\).
- **normlzG** – Image normalization parameters for green channel. **WARNING:**

    - normlz.sub \((s\_g)\) has a limited valid range of \(-255 \le s\_g \le 255\).
    - normlz.mul \((m\_g)\) has a limited valid range of \(-4 \le m\_g \le 4\).
    - normlz.add \((a\_g)\) has a limited valid range of \(-255 \le a\_g \le 255\).
- **normlzB** – Image normalization parameters for blue channel. **WARNING:**

    - normlz.sub \((s\_b)\) has a limited valid range of \(-255 \le s\_b \le 255\).
    - normlz.mul \((m\_b)\) has a limited valid range of \(-4 \le m\_b \le 4\).
    - normlz.add \((a\_b)\) has a limited valid range of \(-255 \le a\_b \le 255\).
- **dstROI** – Region of interest in output image.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_Y8UV8ToRGB888([FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst, [FadasROI\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_r_o_i__t.html#_CPPv410FadasROI_t) \*dstROI)

    - Convert a Y8UV8 image to RGB888.

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).
- **dstROI** – Region of interest in output image.

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY10UV8By2(const [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst)

    - Scale multiplane image (*e.g*., Y and UV) down by two in dimension (four in resolution).

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t). Image format supported Y10UV8 (P01008)
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

- [FadasError\_e](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#_CPPv412FadasError_e) FadasCvtYUV\_DownscaleY12UV8By2(const [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*src, [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#_CPPv412FadasImage_t) \*dst)

    - Scale multiplane image (*e.g*., Y and UV) down by two in dimension (four in resolution).

- Parameters:

    - - **src** – Pointer to the input image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t). Image format supported Y12UV8 (P01208)
- **dst** – Pointer to the output image object of type [FadasImage\_t](https://docs.qualcomm.com/doc/80-63309-1/topic/struct_fadas_image__t.html#struct_fadas_image__t).

- Returns:

    - [FADAS\_ERROR\_NONE](https://docs.qualcomm.com/doc/80-63309-1/topic/enum_fadas_8h_1a280abf443019bfc722ac1158e5fe1013.html#fadas_8h_1a280abf443019bfc722ac1158e5fe1013aea09a4171f0866f38326d7e5323f2d12) — Success.

Last Published: Sep 30, 2024

[Previous Topic
Image Conversion](https://docs.qualcomm.com/bundle/publicresource/80-63309-1/topics/image-conversion.md) [Next Topic
Error Correction Code](https://docs.qualcomm.com/bundle/publicresource/80-63309-1/topics/error-correction-code.md)