Simd Library Documentation.

Home | Release Notes | Download | Documentation | Issues | GitHub | SourceForge

Functions for YUV image conversions. More...

Functions

SIMD_API void SimdYuv420pToBgr (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *bgr, size_t bgrStride)
 Converts YUV420P image to 24-bit BGR image. More...
 
SIMD_API void SimdYuv422pToBgr (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *bgr, size_t bgrStride)
 Converts YUV422P image to 24-bit BGR image. More...
 
SIMD_API void SimdYuv444pToBgr (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *bgr, size_t bgrStride)
 Converts YUV444P image to 24-bit BGR image. More...
 
SIMD_API void SimdYuv420pToBgra (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *bgra, size_t bgraStride, uint8_t alpha)
 Converts YUV420P image to 32-bit BGRA image. More...
 
SIMD_API void SimdYuv422pToBgra (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *bgra, size_t bgraStride, uint8_t alpha)
 Converts YUV422P image to 32-bit BGRA image. More...
 
SIMD_API void SimdYuv444pToBgra (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *bgra, size_t bgraStride, uint8_t alpha)
 Converts YUV444P image to 32-bit BGRA image. More...
 
SIMD_API void SimdYuv444pToHsl (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *hsl, size_t hslStride)
 Converts YUV444P image to 24-bit HSL(Hue, Saturation, Lightness) image. More...
 
SIMD_API void SimdYuv444pToHsv (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *hsv, size_t hsvStride)
 Converts YUV444P image to 24-bit HSV(Hue, Saturation, Value) image. More...
 
SIMD_API void SimdYuv420pToHue (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *hue, size_t hueStride)
 Converts YUV420P image to 8-bit image with Hue component of HSV or HSL color space. More...
 
SIMD_API void SimdYuv444pToHue (const uint8_t *y, size_t yStride, const uint8_t *u, size_t uStride, const uint8_t *v, size_t vStride, size_t width, size_t height, uint8_t *hue, size_t hueStride)
 Converts YUV444P image to 8-bit image with Hue component of HSV or HSL color space. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv420pToBgr (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &bgr)
 Converts YUV420P image to 24-bit BGR image. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv422pToBgr (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &bgr)
 Converts YUV422P image to 24-bit BGR image. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv444pToBgr (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &bgr)
 Converts YUV444P image to 24-bit BGR image. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv420pToBgra (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &bgra, uint8_t alpha=0xFF)
 Converts YUV420P image to 32-bit BGRA image. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv422pToBgra (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &bgra, uint8_t alpha=0xFF)
 Converts YUV422P image to 32-bit BGRA image. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv444pToBgra (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &bgra, uint8_t alpha=0xFF)
 Converts YUV444P image to 32-bit BGRA image. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv444pToHsl (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &hsl)
 Converts YUV444P image to 24-bit HSL(Hue, Saturation, Lightness) image. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv444pToHsv (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &hsv)
 Converts YUV444P image to 24-bit HSV(Hue, Saturation, Value) image. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv420pToHue (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &hue)
 Converts YUV420P image to 8-bit image with Hue component of HSV or HSL color space. More...
 
template<template< class > class A>
SIMD_INLINE void Yuv444pToHue (const View< A > &y, const View< A > &u, const View< A > &v, View< A > &hue)
 Converts YUV444P image to 8-bit image with Hue component of HSV or HSL color space. More...
 

Detailed Description

Functions for YUV image conversions.

Function Documentation

◆ SimdYuv420pToBgr()

void SimdYuv420pToBgr ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  bgr,
size_t  bgrStride 
)

Converts YUV420P image to 24-bit BGR image.

The input Y and output BGR images must have the same width and height. The input U and V images must have the same width and height (half size relative to Y component).

Note
This function has a C++ wrappers: Simd::Yuv420pToBgr(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& bgr);
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]bgr- a pointer to pixels data of output 24-bit BGR image.
[in]bgrStride- a row size of the bgr image.

◆ SimdYuv422pToBgr()

void SimdYuv422pToBgr ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  bgr,
size_t  bgrStride 
)

Converts YUV422P image to 24-bit BGR image.

The input Y and output BGR images must have the same width and height. The input U and V images must have the same width and height (their width is equal to half width of Y component).

Note
This function has a C++ wrappers: Simd::Yuv422pToBgr(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& bgr);
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]bgr- a pointer to pixels data of output 24-bit BGR image.
[in]bgrStride- a row size of the bgr image.

◆ SimdYuv444pToBgr()

void SimdYuv444pToBgr ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  bgr,
size_t  bgrStride 
)

Converts YUV444P image to 24-bit BGR image.

The input Y, U, V and output BGR images must have the same width and height.

Note
This function has a C++ wrappers: Simd::Yuv444pToBgr(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& bgr);
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]bgr- a pointer to pixels data of output 24-bit BGR image.
[in]bgrStride- a row size of the bgr image.

◆ SimdYuv420pToBgra()

void SimdYuv420pToBgra ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  bgra,
size_t  bgraStride,
uint8_t  alpha 
)

Converts YUV420P image to 32-bit BGRA image.

The input Y and output BGRA images must have the same width and height. The input U and V images must have the same width and height (half size relative to Y component).

Note
This function has a C++ wrappers: Simd::Yuv420pToBgra(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& bgra, uint8_t alpha).
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]bgra- a pointer to pixels data of output 32-bit BGRA image.
[in]bgraStride- a row size of the bgra image.
[in]alpha- a value of alpha channel.

◆ SimdYuv422pToBgra()

void SimdYuv422pToBgra ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  bgra,
size_t  bgraStride,
uint8_t  alpha 
)

Converts YUV422P image to 32-bit BGRA image.

The input Y and output BGRA images must have the same width and height. The input U and V images must have the same width and height (their width is equal to half width of Y component).

Note
This function has a C++ wrappers: Simd::Yuv422pToBgra(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& bgra, uint8_t alpha).
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]bgra- a pointer to pixels data of output 32-bit BGRA image.
[in]bgraStride- a row size of the bgra image.
[in]alpha- a value of alpha channel.

◆ SimdYuv444pToBgra()

void SimdYuv444pToBgra ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  bgra,
size_t  bgraStride,
uint8_t  alpha 
)

Converts YUV444P image to 32-bit BGRA image.

The input Y, U, V and output BGRA images must have the same width and height.

Note
This function has a C++ wrappers: Simd::Yuv444pToBgra(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& bgra, uint8_t alpha).
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]bgra- a pointer to pixels data of output 32-bit BGRA image.
[in]bgraStride- a row size of the bgra image.
[in]alpha- a value of alpha channel.

◆ SimdYuv444pToHsl()

void SimdYuv444pToHsl ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  hsl,
size_t  hslStride 
)

Converts YUV444P image to 24-bit HSL(Hue, Saturation, Lightness) image.

The input Y, U, V and output HSL images must have the same width and height.

Note
This function has a C++ wrappers: Simd::Yuv444pToHsl(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& hsl).
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]hsl- a pointer to pixels data of output 24-bit HSL image.
[in]hslStride- a row size of the hsl image.

◆ SimdYuv444pToHsv()

void SimdYuv444pToHsv ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  hsv,
size_t  hsvStride 
)

Converts YUV444P image to 24-bit HSV(Hue, Saturation, Value) image.

The input Y, U, V and output HSV images must have the same width and height.

Note
This function has a C++ wrappers: Simd::Yuv444pToHsv(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& hsv).
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]hsv- a pointer to pixels data of output 24-bit HSV image.
[in]hsvStride- a row size of the hsv image.

◆ SimdYuv420pToHue()

void SimdYuv420pToHue ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  hue,
size_t  hueStride 
)

Converts YUV420P image to 8-bit image with Hue component of HSV or HSL color space.

The input Y and output Hue images must have the same width and height. The input U and V images must have the same width and height (half size relative to Y component).

Note
This function has a C++ wrappers: Simd::Yuv420pToHue(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& hue).
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]hue- a pointer to pixels data of output 8-bit Hue image.
[in]hueStride- a row size of the hue image.

◆ SimdYuv444pToHue()

void SimdYuv444pToHue ( const uint8_t *  y,
size_t  yStride,
const uint8_t *  u,
size_t  uStride,
const uint8_t *  v,
size_t  vStride,
size_t  width,
size_t  height,
uint8_t *  hue,
size_t  hueStride 
)

Converts YUV444P image to 8-bit image with Hue component of HSV or HSL color space.

The input Y, U, V and output Hue images must have the same width and height.

Note
This function has a C++ wrappers: Simd::Yuv444pToHue(const View<A>& y, const View<A>& u, const View<A>& v, View<A>& hue).
Parameters
[in]y- a pointer to pixels data of input 8-bit image with Y color plane.
[in]yStride- a row size of the y image.
[in]u- a pointer to pixels data of input 8-bit image with U color plane.
[in]uStride- a row size of the u image.
[in]v- a pointer to pixels data of input 8-bit image with V color plane.
[in]vStride- a row size of the v image.
[in]width- an image width.
[in]height- an image height.
[out]hue- a pointer to pixels data of output 8-bit Hue image.
[in]hueStride- a row size of the hue image.

◆ Yuv420pToBgr()

void Yuv420pToBgr ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  bgr 
)

Converts YUV420P image to 24-bit BGR image.

The input Y and output BGR images must have the same width and height. The input U and V images must have the same width and height (half size relative to Y component).

Note
This function is a C++ wrapper for function SimdYuv420pToBgr.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]bgr- an output 24-bit BGR image.

◆ Yuv422pToBgr()

void Yuv422pToBgr ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  bgr 
)

Converts YUV422P image to 24-bit BGR image.

The input Y and output BGR images must have the same width and height. The input U and V images must have the same width and height (their width is equal to half width of Y component).

Note
This function is a C++ wrapper for function SimdYuv422pToBgr.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]bgr- an output 24-bit BGR image.

◆ Yuv444pToBgr()

void Yuv444pToBgr ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  bgr 
)

Converts YUV444P image to 24-bit BGR image.

The input Y, U, V and output BGR images must have the same width and height.

Note
This function is a C++ wrapper for function SimdYuv444pToBgr.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]bgr- an output 24-bit BGR image.

◆ Yuv420pToBgra()

void Yuv420pToBgra ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  bgra,
uint8_t  alpha = 0xFF 
)

Converts YUV420P image to 32-bit BGRA image.

The input Y and output BGRA images must have the same width and height. The input U and V images must have the same width and height (half size relative to Y component).

Note
This function is a C++ wrapper for function SimdYuv420pToBgra.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]bgra- an output 32-bit BGRA image.
[in]alpha- a value of alpha channel. It is equal to 255 by default.

◆ Yuv422pToBgra()

void Yuv422pToBgra ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  bgra,
uint8_t  alpha = 0xFF 
)

Converts YUV422P image to 32-bit BGRA image.

The input Y and output BGRA images must have the same width and height. The input U and V images must have the same width and height (their width is equal to half width of Y component).

Note
This function is a C++ wrapper for function SimdYuv422pToBgra.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]bgra- an output 32-bit BGRA image.
[in]alpha- a value of alpha channel. It is equal to 255 by default.

◆ Yuv444pToBgra()

void Yuv444pToBgra ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  bgra,
uint8_t  alpha = 0xFF 
)

Converts YUV444P image to 32-bit BGRA image.

The input Y, U, V and output BGRA images must have the same width and height.

Note
This function is a C++ wrapper for function SimdYuv444pToBgra.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]bgra- an output 32-bit BGRA image.
[in]alpha- a value of alpha channel. It is equal to 255 by default.

◆ Yuv444pToHsl()

void Yuv444pToHsl ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  hsl 
)

Converts YUV444P image to 24-bit HSL(Hue, Saturation, Lightness) image.

The input Y, U, V and output HSL images must have the same width and height.

Note
This function is a C++ wrapper for function SimdYuv444pToHsl.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]hsl- an output 24-bit HSL image.

◆ Yuv444pToHsv()

void Yuv444pToHsv ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  hsv 
)

Converts YUV444P image to 24-bit HSV(Hue, Saturation, Value) image.

The input Y, U, V and output HSV images must have the same width and height.

Note
This function is a C++ wrapper for function SimdYuv444pToHsv.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]hsv- an output 24-bit HSV image.

◆ Yuv420pToHue()

void Yuv420pToHue ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  hue 
)

Converts YUV420P image to 8-bit image with Hue component of HSV or HSL color space.

The input Y and output Hue images must have the same width and height. The input U and V images must have the same width and height (half size relative to Y component).

Note
This function is a C++ wrapper for function SimdYuv420pToHue.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]hue- an output 8-bit Hue image.

◆ Yuv444pToHue()

void Yuv444pToHue ( const View< A > &  y,
const View< A > &  u,
const View< A > &  v,
View< A > &  hue 
)

Converts YUV444P image to 8-bit image with Hue component of HSV or HSL color space.

The input Y, U, V and output Hue images must have the same width and height.

Note
This function is a C++ wrapper for function SimdYuv444pToHue.
Parameters
[in]y- an input 8-bit image with Y color plane.
[in]u- an input 8-bit image with U color plane.
[in]v- an input 8-bit image with V color plane.
[out]hue- an output 8-bit Hue image.