Image Color Conversion Functions
Routines manipulating an image’s color model and sampling format.
These functions can be found in the nppicc library. Linking to only the sub-libraries that you use can significantly save link time, application load time, and CUDA runtime startup time when using dynamic libraries.
Color Processing Functions
Routines for performing image color manipulation.
RGBToYUVColorTwist
Normally, color twist is a 3-channel operation that takes place on RGB data.
The following functions also perform the color twist operation, but while converting between image formats: RGBToYUV420, RGBToYUV422, and RGBToNV12.
To recap color twist pixel processing: Color twist consists of applying the following formula to each image pixel using coefficients from the user supplied color twist host matrix array as follows where dst[x] and src[x] represent destination pixel and source pixel channel or plane x. The full sized coefficient matrix should be sent for all pixel channel sizes, the function will process the appropriate coefficients and channels for the corresponding pixel size.
This is how the matrix works for a RGB->YUV420/YUV422/NV12 forward transform:
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3]
dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3]
dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3]
-
NppStatus nppiRGBToYUV420_8u_ColorTwist32f_P3R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar RGB convertion to three channel 8-bit unsigned planar YUV 4:2:0, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToYUV420_16u_ColorTwist32f_P3R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned planar RGB convertion to three channel 16-bit unsigned planar YUV 4:2:0, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToYUV420_8u_ColorTwist32f_C3P3R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned packed RGB convertion to three channel 8-bit unsigned planar YUV 4:2:0, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToYUV420_16u_ColorTwist32f_C3P3R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned packed RGB convertion to three channel 16-bit unsigned planar YUV 4:2:0, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToYUV422_8u_ColorTwist32f_P3R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar RGB convertion to three channel 8-bit unsigned planar YUV 4:2:2, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToYUV422_16u_ColorTwist32f_P3R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned planar RGB convertion to three channel 16-bit unsigned planar YUV 4:2:2, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToYUV422_8u_ColorTwist32f_C3C2R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned packed RGB convertion to two channel 8-bit unsigned packed YUV 4:2:2, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToYUV422_16u_ColorTwist32f_C3C2R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned packed RGB convertion to two channel 16-bit unsigned packed YUV 4:2:2, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToYUV422_8u_ColorTwist32f_C3P3R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned packed RGB convertion to three channel 8-bit unsigned planar YUV 4:2:2, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToYUV422_16u_ColorTwist32f_C3P3R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned packed RGB convertion to three channel 16-bit unsigned planar YUV 4:2:2, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToNV12_8u_ColorTwist32f_C3P2R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst[2], int aDstStep[2], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned packed RGB convertion to two channel 8-bit unsigned planar NV12, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToNV12_16u_ColorTwist32f_C3P2R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst[2], int aDstStep[2], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned packed RGB convertion to two channel 16-bit unsigned planar NV12, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToNV12_8u_ColorTwist32f_P3P2R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst[2], int aDstStep[2], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar RGB convertion to two channel 8-bit unsigned planar NV12, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToNV12_16u_ColorTwist32f_P3P2R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst[2], int aDstStep[2], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned planar RGB convertion to two channel 16-bit unsigned planar NV12, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
YUVToRGBColorTwist
This is the inverse color twist, a 3-channel operation that takes place on YUV/NV12 data to produce RGB data, supporting the following conversions: YUV420ToRGB, YUV422ToRGB, and NV12ToRGB.
The INVERSE Color twist consists of applying the following formula to each image pixel using coefficients from the user supplied color twist host matrix array as follows where dst[x] and src[x] represent destination pixel and source pixel channel or plane x. The full sized coefficient matrix should be sent for all pixel channel sizes, the function will process the appropriate coefficients and channels for the corresponding pixel size.
This is how the matrix works for the YUV420/YUV/422/NV12->RGB INVERSE transform:
(note- do the offsets first):
src[0]' = src[0] + aTwist[0][3]
src[1]' = src[1] + aTwist[1][3]
src[2]' = src[2] + aTwist[2][3]
And then the remaining 3x3 twist matrix is applied using those modified values:
dst[0] = aTwist[0][0] * src[0]' + aTwist[0][1] * src[1]' + aTwist[0][2] * src[2]'
dst[1] = aTwist[1][0] * src[0]' + aTwist[1][1] * src[1]' + aTwist[1][2] * src[2]'
dst[2] = aTwist[2][0] * src[0]' + aTwist[2][1] * src[1]' + aTwist[2][2] * src[2]'
Since the 4th column of the matrix is the offsets (either 0 or half-max to shift the values to be positive), as they’re applied last in the forward transform (to YUV), they need to be applied FIRST in the inverse transform (back to RGB). This does mean that +-16384 has to be used for 16u images where there was a +-128 for 8u images in both forward and inverse cases.
-
NppStatus nppiYUV420ToRGB_8u_ColorTwist32f_P3R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar YUV4:2:0 convertion to three channel 8-bit unsigned planar RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV420ToRGB_16u_ColorTwist32f_P3R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned planar YUV4:2:0 convertion to three channel 16-bit unsigned planar RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV420ToRGB_8u_ColorTwist32f_P3C3R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar YUV4:2:0 convertion to three channel 8-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV420ToRGB_16u_ColorTwist32f_P3C3R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned planar YUV4:2:0 convertion to three channel 16-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV420ToRGB_8u_ColorTwist32f_P3C4R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar YUV4:2:0 convertion to four channel 8-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic, with constant alpha (0xFF).
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV420ToRGB_16u_ColorTwist32f_P3C4R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned planar YUV4:2:0 convertion to four channel 16-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic, with constant alpha (0xFFFF).
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV420ToRGB_8u_ColorTwist32f_P3AC4R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], const Npp8u nAlpha, NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar YUV4:2:0 convertion to four channel 8-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic, with user set alpha.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nAlpha – 8-bit unsigned alpha constant.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV420ToRGB_16u_ColorTwist32f_P3AC4R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], const Npp16u nAlpha, NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned planar YUV4:2:0 convertion to four channel 16-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic, with user set alpha.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nAlpha – 16-bit unsigned alpha constant.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV422ToRGB_8u_ColorTwist32f_C2C3R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Two channel 8-bit unsigned packed YUV4:2:2 convertion to three channel 8-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV422ToRGB_16u_ColorTwist32f_C2C3R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Two channel 16-bit unsigned packed YUV4:2:2 convertion to three channel 16-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV422ToRGB_8u_ColorTwist32f_P3R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar YUV4:2:2 convertion to three channel 8-bit unsigned planar RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV422ToRGB_16u_ColorTwist32f_P3R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst[3], int aDstStep[3], NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned planar YUV4:2:2 convertion to three channel 16-bit unsigned planar RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
aDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV422ToRGB_8u_ColorTwist32f_P3C3R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar YUV4:2:2 convertion to three channel 8-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV422ToRGB_16u_ColorTwist32f_P3C3R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar YUV4:2:2 convertion to three channel 8-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV422ToRGB_8u_ColorTwist32f_P3AC4R_Ctx(const Npp8u *const pSrc[3], int aSrcStep[3], Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], const Npp8u nAlpha, NppStreamContext nppStreamCtx)
Three channel 8-bit unsigned planar YUV4:2:2 convertion to three channel 8-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic, with user set alpha.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nAlpha – 8-bit unsigned alpha constant.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiYUV422ToRGB_16u_ColorTwist32f_P3AC4R_Ctx(const Npp16u *const pSrc[3], int aSrcStep[3], Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], const Npp16u nAlpha, NppStreamContext nppStreamCtx)
Three channel 16-bit unsigned planar YUV4:2:2 convertion to three channel 16-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic, with user set alpha.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nAlpha – 16-bit unsigned alpha constant.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiNV12ToRGB_8u_ColorTwist32f_P2C3R_Ctx(const Npp8u *const pSrc[2], int aSrcStep[2], Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Two channel 8-bit unsigned planar NV12 convertion to three channel 8-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiNV12ToRGB_16u_ColorTwist32f_P2C3R_Ctx(const Npp16u *const pSrc[2], int aSrcStep[2], Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
Two channel 16-bit unsigned planar NV12 convertion to three channel 16-bit unsigned packed RGB, using a Color Twist to compute the exact color space arithmetic.
- Parameters
pSrc – Source-Image Pointer.
aSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
Color To Gray Conversion
Routines for converting color images to grayscale.
RGBToGray
RGB to CCIR601 Gray conversion.
Here is how NPP converts gamma corrected RGB to CCIR601 Gray.
nGray = 0.299F * R + 0.587F * G + 0.114F * B;
-
NppStatus nppiRGBToGray_8u_C3C1R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned packed RGB to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToGray_8u_C3C1R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI)
3 channel 8-bit unsigned packed RGB to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiRGBToGray_8u_AC4C1R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned packed RGB with alpha to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToGray_8u_AC4C1R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI)
4 channel 8-bit unsigned packed RGB with alpha to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiRGBToGray_16u_C3C1R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 16-bit unsigned packed RGB to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToGray_16u_C3C1R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI)
3 channel 16-bit unsigned packed RGB to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiRGBToGray_16u_AC4C1R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
4 channel 16-bit unsigned packed RGB with alpha to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToGray_16u_AC4C1R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI)
4 channel 16-bit unsigned packed RGB with alpha to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiRGBToGray_16s_C3C1R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 16-bit signed packed RGB to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToGray_16s_C3C1R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI)
3 channel 16-bit signed packed RGB to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiRGBToGray_16s_AC4C1R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
4 channel 16-bit signed packed RGB with alpha to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToGray_16s_AC4C1R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI)
4 channel 16-bit signed packed RGB with alpha to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiRGBToGray_32f_C3C1R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 32-bit floating point packed RGB to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToGray_32f_C3C1R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI)
3 channel 32-bit floating point packed RGB to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiRGBToGray_32f_AC4C1R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
4 channel 32-bit floating point packed RGB with alpha to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiRGBToGray_32f_AC4C1R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI)
4 channel 32-bit floating point packed RGB with alpha to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
ColorToGray
RGB Color to Gray conversion using user supplied conversion coefficients.
Here is how NPP converts gamma corrected RGB Color to Gray using user supplied conversion coefficients.
nGray = aCoeffs[0] * R + aCoeffs[1] * G + aCoeffs[2] * B;
For the C4C1R versions of the functions the calculations are as follows.
For BGRA or other formats with alpha just rearrange the coefficients accordingly.
nGray = aCoeffs[0] * R + aCoeffs[1] * G + aCoeffs[2] * B + aCoeffs[3] * A;
-
NppStatus nppiColorToGray_8u_C3C1R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3], NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned packed RGB to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_8u_C3C1R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3])
3 channel 8-bit unsigned packed RGB to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_8u_AC4C1R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3], NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned packed RGB with alpha to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_8u_AC4C1R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3])
4 channel 8-bit unsigned packed RGB with alpha to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_8u_C4C1R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[4], NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned packed RGBA to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_8u_C4C1R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[4])
4 channel 8-bit unsigned packed RGBA to 1 channel 8-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_16u_C3C1R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3], NppStreamContext nppStreamCtx)
3 channel 16-bit unsigned packed RGB to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_16u_C3C1R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3])
3 channel 16-bit unsigned packed RGB to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_16u_AC4C1R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3], NppStreamContext nppStreamCtx)
4 channel 16-bit unsigned packed RGB with alpha to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_16u_AC4C1R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3])
4 channel 16-bit unsigned packed RGB with alpha to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_16u_C4C1R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[4], NppStreamContext nppStreamCtx)
4 channel 16-bit unsigned packed RGBA to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_16u_C4C1R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[4])
4 channel 16-bit unsigned packed RGBA to 1 channel 16-bit unsigned packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_16s_C3C1R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3], NppStreamContext nppStreamCtx)
3 channel 16-bit signed packed RGB to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_16s_C3C1R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3])
3 channel 16-bit signed packed RGB to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_16s_AC4C1R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3], NppStreamContext nppStreamCtx)
4 channel 16-bit signed packed RGB with alpha to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_16s_AC4C1R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3])
4 channel 16-bit signed packed RGB with alpha to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_16s_C4C1R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[4], NppStreamContext nppStreamCtx)
4 channel 16-bit signed packed RGBA to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_16s_C4C1R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[4])
4 channel 16-bit signed packed RGBA to 1 channel 16-bit signed packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_32f_C3C1R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3], NppStreamContext nppStreamCtx)
3 channel 32-bit floating point packed RGB to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_32f_C3C1R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3])
3 channel 32-bit floating point packed RGB to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_32f_AC4C1R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3], NppStreamContext nppStreamCtx)
4 channel 32-bit floating point packed RGB with alpha to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_32f_AC4C1R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[3])
4 channel 32-bit floating point packed RGB with alpha to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
-
NppStatus nppiColorToGray_32f_C4C1R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[4], NppStreamContext nppStreamCtx)
4 channel 32-bit floating point packed RGBA to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorToGray_32f_C4C1R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aCoeffs[4])
4 channel 32-bit floating point packed RGBA to 1 channel 32-bit floating point packed Gray conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aCoeffs – fixed size array of constant floating point conversion coefficient values, one per color channel.
- Returns
GradientColorToGray
RGB Color to Gray Gradient conversion using user selected gradient distance method.
-
NppStatus nppiGradientColorToGray_8u_C3C1R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, NppiNorm eNorm, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned packed RGB to 1 channel 8-bit unsigned packed Gray Gradient conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
eNorm – Gradient distance method to use.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGradientColorToGray_8u_C3C1R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, NppiNorm eNorm)
3 channel 8-bit unsigned packed RGB to 1 channel 8-bit unsigned packed Gray Gradient conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
eNorm – Gradient distance method to use.
- Returns
-
NppStatus nppiGradientColorToGray_16u_C3C1R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, NppiNorm eNorm, NppStreamContext nppStreamCtx)
3 channel 16-bit unsigned packed RGB to 1 channel 16-bit unsigned packed Gray Gradient conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
eNorm – Gradient distance method to use.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGradientColorToGray_16u_C3C1R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, NppiNorm eNorm)
3 channel 16-bit unsigned packed RGB to 1 channel 16-bit unsigned packed Gray Gradient conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
eNorm – Gradient distance method to use.
- Returns
-
NppStatus nppiGradientColorToGray_16s_C3C1R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, NppiNorm eNorm, NppStreamContext nppStreamCtx)
3 channel 16-bit signed packed RGB to 1 channel 16-bit signed packed Gray Gradient conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
eNorm – Gradient distance method to use.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGradientColorToGray_16s_C3C1R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, NppiNorm eNorm)
3 channel 16-bit signed packed RGB to 1 channel 16-bit signed packed Gray Gradient conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
eNorm – Gradient distance method to use.
- Returns
-
NppStatus nppiGradientColorToGray_32f_C3C1R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, NppiNorm eNorm, NppStreamContext nppStreamCtx)
3 channel 32-bit floating point packed RGB to 1 channel 32-bit floating point packed Gray Gradient conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
eNorm – Gradient distance method to use.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGradientColorToGray_32f_C3C1R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, NppiNorm eNorm)
3 channel 32-bit floating point packed RGB to 1 channel 32-bit floating point packed Gray Gradient conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
eNorm – Gradient distance method to use.
- Returns
Color Debayer
Grayscale Color Filter Array to RGB Color Debayer conversion.
Generates one RGB color pixel for every grayscale source pixel. Source and destination images must have even width and height. Missing pixel colors are generated using bilinear interpolation with chroma correlation of generated green values (eInterpolation MUST be set to 0). eGrid allows the user to specify the Bayer grid registration position at source image location oSrcROI.x, oSrcROI.y relative to pSrc. Possible registration positions are:
NPPI_BAYER_BGGR NPPI_BAYER_RGGB NPPI_BAYER_GBRG NPPI_BAYER_GRBG
B G R G G B G R
G R G B R G B G
If it becomes necessary to access source pixels outside source image then the source image borders are mirrored.
Here is how the algorithm works. R, G, and B base pixels from the source image are used unmodified. To generate R values for those G pixels, the average of R(x - 1, y) and R(x + 1, y) or R(x, y - 1) and R(x, y + 1) is used depending on whether the left and right or top and bottom pixels are R base pixels. To generate B values for those G pixels, the same algorithm is used using nearest B values. For an R base pixel, if there are no B values in the upper, lower, left, or right adjacent pixels then B is the average of B values in the 4 diagonal (G base) pixels. The same algorithm is used using R values to generate the R value of a B base pixel. Chroma correlation is applied to generated G values only, for a B base pixel G(x - 1, y) and G(x + 1, y) are averaged or G(x, y - 1) and G(x, y + 1) are averaged depending on whether the absolute difference between B(x, y) and the average of B(x - 2, y) and B(x + 2, y) is smaller than the absolute difference between B(x, y) and the average of B(x, y - 2) and B(x, y + 2). For an R base pixel the same algorithm is used testing against the surrounding R values at those offsets. If the horizontal and vertical differences are the same at one of those pixels then the average of the four left, right, upper and lower G values is used instead.
Functions
-
NppStatus nppiCFAToRGB_8u_C1C3R_Ctx(const Npp8u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiRect oSrcROI, Npp8u *pDst, int nDstStep, NppiBayerGridPosition eGrid, NppiInterpolationMode eInterpolation, NppStreamContext nppStreamCtx)
1 channel 8-bit unsigned packed CFA grayscale Bayer pattern to 3 channel 8-bit unsigned packed RGB conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
oSrcSize – full source image width and height relative to pSrc.
oSrcROI – rectangle specifying starting source image pixel x and y location relative to pSrc and ROI width and height.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
eGrid – enumeration value specifying bayer grid registration position at location oSrcROI.x, oSrcROI.y relative to pSrc.
eInterpolation – MUST be NPPI_INTER_UNDEFINED
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiCFAToRGB_8u_C1C3R(const Npp8u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiRect oSrcROI, Npp8u *pDst, int nDstStep, NppiBayerGridPosition eGrid, NppiInterpolationMode eInterpolation)
1 channel 8-bit unsigned packed CFA grayscale Bayer pattern to 3 channel 8-bit unsigned packed RGB conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
oSrcSize – full source image width and height relative to pSrc.
oSrcROI – rectangle specifying starting source image pixel x and y location relative to pSrc and ROI width and height.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
eGrid – enumeration value specifying bayer grid registration position at location oSrcROI.x, oSrcROI.y relative to pSrc.
eInterpolation – MUST be NPPI_INTER_UNDEFINED
- Returns
-
NppStatus nppiCFAToRGBA_8u_C1AC4R_Ctx(const Npp8u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiRect oSrcROI, Npp8u *pDst, int nDstStep, NppiBayerGridPosition eGrid, NppiInterpolationMode eInterpolation, Npp8u nAlpha, NppStreamContext nppStreamCtx)
1 channel 8-bit unsigned packed CFA grayscale Bayer pattern to 4 channel 8-bit unsigned packed RGB conversion with alpha.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
oSrcSize – full source image width and height relative to pSrc.
oSrcROI – rectangle specifying starting source image pixel x and y location relative to pSrc and ROI width and height.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
eGrid – enumeration value specifying bayer grid registration position at location oSrcROI.x, oSrcROI.y relative to pSrc.
eInterpolation – MUST be NPPI_INTER_UNDEFINED
nAlpha – constant alpha value to be written to each destination pixel
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiCFAToRGBA_8u_C1AC4R(const Npp8u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiRect oSrcROI, Npp8u *pDst, int nDstStep, NppiBayerGridPosition eGrid, NppiInterpolationMode eInterpolation, Npp8u nAlpha)
1 channel 8-bit unsigned packed CFA grayscale Bayer pattern to 4 channel 8-bit unsigned packed RGB conversion with alpha.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
oSrcSize – full source image width and height relative to pSrc.
oSrcROI – rectangle specifying starting source image pixel x and y location relative to pSrc and ROI width and height.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
eGrid – enumeration value specifying bayer grid registration position at location oSrcROI.x, oSrcROI.y relative to pSrc.
eInterpolation – MUST be NPPI_INTER_UNDEFINED
nAlpha – constant alpha value to be written to each destination pixel
- Returns
-
NppStatus nppiCFAToRGB_16u_C1C3R_Ctx(const Npp16u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiRect oSrcROI, Npp16u *pDst, int nDstStep, NppiBayerGridPosition eGrid, NppiInterpolationMode eInterpolation, NppStreamContext nppStreamCtx)
1 channel 16-bit unsigned packed CFA grayscale Bayer pattern to 3 channel 16-bit unsigned packed RGB conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
oSrcSize – full source image width and height relative to pSrc.
oSrcROI – rectangle specifying starting source image pixel x and y location relative to pSrc and ROI width and height.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
eGrid – enumeration value specifying bayer grid registration position at location oSrcROI.x, oSrcROI.y relative to pSrc.
eInterpolation – MUST be NPPI_INTER_UNDEFINED
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiCFAToRGB_16u_C1C3R(const Npp16u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiRect oSrcROI, Npp16u *pDst, int nDstStep, NppiBayerGridPosition eGrid, NppiInterpolationMode eInterpolation)
1 channel 16-bit unsigned packed CFA grayscale Bayer pattern to 3 channel 16-bit unsigned packed RGB conversion.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
oSrcSize – full source image width and height relative to pSrc.
oSrcROI – rectangle specifying starting source image pixel x and y location relative to pSrc and ROI width and height.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
eGrid – enumeration value specifying bayer grid registration position at location oSrcROI.x, oSrcROI.y relative to pSrc.
eInterpolation – MUST be NPPI_INTER_UNDEFINED
- Returns
-
NppStatus nppiCFAToRGBA_16u_C1AC4R_Ctx(const Npp16u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiRect oSrcROI, Npp16u *pDst, int nDstStep, NppiBayerGridPosition eGrid, NppiInterpolationMode eInterpolation, Npp16u nAlpha, NppStreamContext nppStreamCtx)
1 channel 16-bit unsigned packed CFA grayscale Bayer pattern to 4 channel 16-bit unsigned packed RGB conversion with alpha.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
oSrcSize – full source image width and height relative to pSrc.
oSrcROI – rectangle specifying starting source image pixel x and y location relative to pSrc and ROI width and height.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
eGrid – enumeration value specifying bayer grid registration position at location oSrcROI.x, oSrcROI.y relative to pSrc.
eInterpolation – MUST be NPPI_INTER_UNDEFINED
nAlpha – constant alpha value to be written to each destination pixel
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiCFAToRGBA_16u_C1AC4R(const Npp16u *pSrc, int nSrcStep, NppiSize oSrcSize, NppiRect oSrcROI, Npp16u *pDst, int nDstStep, NppiBayerGridPosition eGrid, NppiInterpolationMode eInterpolation, Npp16u nAlpha)
1 channel 16-bit unsigned packed CFA grayscale Bayer pattern to 4 channel 16-bit unsigned packed RGB conversion with alpha.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
oSrcSize – full source image width and height relative to pSrc.
oSrcROI – rectangle specifying starting source image pixel x and y location relative to pSrc and ROI width and height.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
eGrid – enumeration value specifying bayer grid registration position at location oSrcROI.x, oSrcROI.y relative to pSrc.
eInterpolation – MUST be NPPI_INTER_UNDEFINED
nAlpha – constant alpha value to be written to each destination pixel
- Returns
Color Gamma Correction
Routines for correcting image color gamma.
GammaFwd
Forward gamma correction.
-
NppStatus nppiGammaFwd_8u_C3R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned packed color not in place forward gamma correction.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaFwd_8u_C3R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI)
3 channel 8-bit unsigned packed color not in place forward gamma correction.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaFwd_8u_C3IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned packed color in place forward gamma correction.
- Parameters
pSrcDst – in place packed pixel image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaFwd_8u_C3IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI)
3 channel 8-bit unsigned packed color in place forward gamma correction.
- Parameters
pSrcDst – in place packed pixel image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaFwd_8u_AC4R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned packed color with alpha not in place forward gamma correction.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaFwd_8u_AC4R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI)
4 channel 8-bit unsigned packed color with alpha not in place forward gamma correction.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaFwd_8u_AC4IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned packed color with alpha in place forward gamma correction.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaFwd_8u_AC4IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI)
4 channel 8-bit unsigned packed color with alpha in place forward gamma correction.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaFwd_8u_P3R_Ctx(const Npp8u *const pSrc[3], int nSrcStep, Npp8u *pDst[3], int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned planar color not in place forward gamma correction.
- Parameters
pSrc – source planar pixel format image pointer array.
nSrcStep – source planar pixel format image line step.
pDst – destination planar pixel format image pointer array.
nDstStep – destination planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaFwd_8u_P3R(const Npp8u *const pSrc[3], int nSrcStep, Npp8u *pDst[3], int nDstStep, NppiSize oSizeROI)
3 channel 8-bit unsigned planar color not in place forward gamma correction.
- Parameters
pSrc – source planar pixel format image pointer array.
nSrcStep – source planar pixel format image line step.
pDst – destination planar pixel format image pointer array.
nDstStep – destination planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaFwd_8u_IP3R_Ctx(Npp8u *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned planar color in place forward gamma correction.
- Parameters
pSrcDst – in place planar pixel format image pointer array.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaFwd_8u_IP3R(Npp8u *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI)
3 channel 8-bit unsigned planar color in place forward gamma correction.
- Parameters
pSrcDst – in place planar pixel format image pointer array.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
GammaInv
Inverse gamma correction.
-
NppStatus nppiGammaInv_8u_C3R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned packed color not in place inverse gamma correction.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaInv_8u_C3R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI)
3 channel 8-bit unsigned packed color not in place inverse gamma correction.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaInv_8u_C3IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned packed color in place inverse gamma correction.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaInv_8u_C3IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI)
3 channel 8-bit unsigned packed color in place inverse gamma correction.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaInv_8u_AC4R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned packed color with alpha not in place inverse gamma correction.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaInv_8u_AC4R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI)
4 channel 8-bit unsigned packed color with alpha not in place inverse gamma correction.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaInv_8u_AC4IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned packed color with alpha in place inverse gamma correction.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaInv_8u_AC4IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI)
4 channel 8-bit unsigned packed color with alpha in place inverse gamma correction.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaInv_8u_P3R_Ctx(const Npp8u *const pSrc[3], int nSrcStep, Npp8u *pDst[3], int nDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned planar color not in place inverse gamma correction.
- Parameters
pSrc – source planar pixel format image pointer array.
nSrcStep – source planar pixel format image line step.
pDst – destination planar pixel format image pointer array.
nDstStep – destination planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaInv_8u_P3R(const Npp8u *const pSrc[3], int nSrcStep, Npp8u *pDst[3], int nDstStep, NppiSize oSizeROI)
3 channel 8-bit unsigned planar color not in place inverse gamma correction.
- Parameters
pSrc – source planar pixel format image pointer array.
nSrcStep – source planar pixel format image line step.
pDst – destination planar pixel format image pointer array.
nDstStep – destination planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
-
NppStatus nppiGammaInv_8u_IP3R_Ctx(Npp8u *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned planar color in place inverse gamma correction.
- Parameters
pSrcDst – in place planar pixel format image pointer array.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiGammaInv_8u_IP3R(Npp8u *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI)
3 channel 8-bit unsigned planar color in place inverse gamma correction.
- Parameters
pSrcDst – in place planar pixel format image pointer array.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
- Returns
Complement Color Key
Routines for performing complement color key replacement.
CompColorKey
Complement color key replacement.
-
NppStatus nppiCompColorKey_8u_C1R_Ctx(const Npp8u *pSrc1, int nSrc1Step, const Npp8u *pSrc2, int nSrc2Step, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, Npp8u nColorKeyConst, NppStreamContext nppStreamCtx)
1 channel 8-bit unsigned packed color complement color key replacement of source image 1 by source image 2.
- Parameters
pSrc1 – source1 packed pixel format image pointer.
nSrc1Step – source1 packed pixel format image line step.
pSrc2 – source2 packed pixel format image pointer.
nSrc2Step – source2 packed pixel format image line step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nColorKeyConst – color key constant
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiCompColorKey_8u_C1R(const Npp8u *pSrc1, int nSrc1Step, const Npp8u *pSrc2, int nSrc2Step, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, Npp8u nColorKeyConst)
1 channel 8-bit unsigned packed color complement color key replacement of source image 1 by source image 2.
- Parameters
pSrc1 – source1 packed pixel format image pointer.
nSrc1Step – source1 packed pixel format image line step.
pSrc2 – source2 packed pixel format image pointer.
nSrc2Step – source2 packed pixel format image line step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nColorKeyConst – color key constant
- Returns
-
NppStatus nppiCompColorKey_8u_C3R_Ctx(const Npp8u *pSrc1, int nSrc1Step, const Npp8u *pSrc2, int nSrc2Step, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, Npp8u nColorKeyConst[3], NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned packed color complement color key replacement of source image 1 by source image 2.
- Parameters
pSrc1 – source1 packed pixel format image pointer.
nSrc1Step – source1 packed pixel format image line step.
pSrc2 – source2 packed pixel format image pointer.
nSrc2Step – source2 packed pixel format image line step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nColorKeyConst – color key constant array
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiCompColorKey_8u_C3R(const Npp8u *pSrc1, int nSrc1Step, const Npp8u *pSrc2, int nSrc2Step, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, Npp8u nColorKeyConst[3])
3 channel 8-bit unsigned packed color complement color key replacement of source image 1 by source image 2.
- Parameters
pSrc1 – source1 packed pixel format image pointer.
nSrc1Step – source1 packed pixel format image line step.
pSrc2 – source2 packed pixel format image pointer.
nSrc2Step – source2 packed pixel format image line step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nColorKeyConst – color key constant array
- Returns
-
NppStatus nppiCompColorKey_8u_C4R_Ctx(const Npp8u *pSrc1, int nSrc1Step, const Npp8u *pSrc2, int nSrc2Step, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, Npp8u nColorKeyConst[4], NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned packed color complement color key replacement of source image 1 by source image 2.
- Parameters
pSrc1 – source1 packed pixel format image pointer.
nSrc1Step – source1 packed pixel format image line step.
pSrc2 – source2 packed pixel format image pointer.
nSrc2Step – source2 packed pixel format image line step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nColorKeyConst – color key constant array
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiCompColorKey_8u_C4R(const Npp8u *pSrc1, int nSrc1Step, const Npp8u *pSrc2, int nSrc2Step, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, Npp8u nColorKeyConst[4])
4 channel 8-bit unsigned packed color complement color key replacement of source image 1 by source image 2.
- Parameters
pSrc1 – source1 packed pixel format image pointer.
nSrc1Step – source1 packed pixel format image line step.
pSrc2 – source2 packed pixel format image pointer.
nSrc2Step – source2 packed pixel format image line step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nColorKeyConst – color key constant array
- Returns
-
NppStatus nppiAlphaCompColorKey_8u_AC4R_Ctx(const Npp8u *pSrc1, int nSrc1Step, Npp8u nAlpha1, const Npp8u *pSrc2, int nSrc2Step, Npp8u nAlpha2, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, Npp8u nColorKeyConst[4], NppiAlphaOp nppAlphaOp, NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned packed color complement color key replacement of source image 1 by source image 2 with alpha blending.
- Parameters
pSrc1 – source1 packed pixel format image pointer.
nSrc1Step – source1 packed pixel format image line step.
nAlpha1 – source1 image alpha opacity (0 - max channel pixel value).
pSrc2 – source2 packed pixel format image pointer.
nSrc2Step – source2 packed pixel format image line step.
nAlpha2 – source2 image alpha opacity (0 - max channel pixel value).
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nColorKeyConst – color key constant array
nppAlphaOp – NppiAlphaOp alpha compositing operation selector (excluding premul ops).
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiAlphaCompColorKey_8u_AC4R(const Npp8u *pSrc1, int nSrc1Step, Npp8u nAlpha1, const Npp8u *pSrc2, int nSrc2Step, Npp8u nAlpha2, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, Npp8u nColorKeyConst[4], NppiAlphaOp nppAlphaOp)
4 channel 8-bit unsigned packed color complement color key replacement of source image 1 by source image 2 with alpha blending.
- Parameters
pSrc1 – source1 packed pixel format image pointer.
nSrc1Step – source1 packed pixel format image line step.
nAlpha1 – source1 image alpha opacity (0 - max channel pixel value).
pSrc2 – source2 packed pixel format image pointer.
nSrc2Step – source2 packed pixel format image line step.
nAlpha2 – source2 image alpha opacity (0 - max channel pixel value).
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
nColorKeyConst – color key constant array
nppAlphaOp – NppiAlphaOp alpha compositing operation selector (excluding premul ops).
- Returns
ColorTwist
Routines for converting between various image color models using user supplied matrix coefficients.
ColorTwist
Perform color twist pixel processing.
Color twist consists of applying the following formula to each image pixel using coefficients from the user supplied color twist host matrix array as follows where dst[x] and src[x] represent destination pixel and source pixel channel or plane x. The full sized coefficient matrix should be sent for all pixel channel sizes, the function will process the appropriate coefficients and channels for the corresponding pixel size.
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3]
dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3]
dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3]
-
NppStatus nppiColorTwist32f_8u_C1R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 8-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_C1R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 8-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_C1IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 8-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_C1IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 8-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_C2R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 8-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_C2R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 8-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_C2IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 8-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_C2IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 8-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_C3R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_C3R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 8-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_C3IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_C3IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 8-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_C4R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned color twist, with alpha copy.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is copied unmodified from the source pixel to the destination pixel.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_C4R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 8-bit unsigned color twist, with alpha copy.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is copied unmodified from the source pixel to the destination pixel.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_C4IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is unmodified.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_C4IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 8-bit unsigned in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is unmodified.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_AC4R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_AC4R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 8-bit unsigned color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_AC4IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_AC4IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 8-bit unsigned in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32fC_8u_C4R_Ctx(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[4][4], const Npp32f aConstants[4], NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned color twist with 4x4 matrix and constant vector addition.
An input 4x4 color twist matrix with floating-point coefficient values with an additional constant vector addition is applied within ROI. For this particular version of the function the result is generated as shown below.
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3] * src[3] + aConstants[0] dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3] * src[3] + aConstants[1] dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3] * src[3] + aConstants[2] dst[3] = aTwist[3][0] * src[0] + aTwist[3][1] * src[1] + aTwist[3][2] * src[2] + aTwist[3][3] * src[3] + aConstants[3]
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
aConstants – fixed size array of constant values, one per channel..
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32fC_8u_C4R(const Npp8u *pSrc, int nSrcStep, Npp8u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[4][4], const Npp32f aConstants[4])
4 channel 8-bit unsigned color twist with 4x4 matrix and constant vector addition.
An input 4x4 color twist matrix with floating-point coefficient values with an additional constant vector addition is applied within ROI. For this particular version of the function the result is generated as shown below.
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3] * src[3] + aConstants[0] dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3] * src[3] + aConstants[1] dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3] * src[3] + aConstants[2] dst[3] = aTwist[3][0] * src[0] + aTwist[3][1] * src[1] + aTwist[3][2] * src[2] + aTwist[3][3] * src[3] + aConstants[3]
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
aConstants – fixed size array of constant values, one per channel..
- Returns
-
NppStatus nppiColorTwist32fC_8u_C4IR_Ctx(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[4][4], const Npp32f aConstants[4], NppStreamContext nppStreamCtx)
4 channel 8-bit unsigned in place color twist with 4x4 matrix and an additional constant vector addition.
An input 4x4 color twist matrix with floating-point coefficient values with an additional constant vector addition is applied within ROI. For this particular version of the function the result is generated as shown below.
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3] * src[3] + aConstants[0] dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3] * src[3] + aConstants[1] dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3] * src[3] + aConstants[2] dst[3] = aTwist[3][0] * src[0] + aTwist[3][1] * src[1] + aTwist[3][2] * src[2] + aTwist[3][3] * src[3] + aConstants[3]
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
aConstants – fixed size array of constant values, one per channel..
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32fC_8u_C4IR(Npp8u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[4][4], const Npp32f aConstants[4])
4 channel 8-bit unsigned in place color twist with 4x4 matrix and an additional constant vector addition.
An input 4x4 color twist matrix with floating-point coefficient values with an additional constant vector addition is applied within ROI. For this particular version of the function the result is generated as shown below.
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3] * src[3] + aConstants[0] dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3] * src[3] + aConstants[1] dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3] * src[3] + aConstants[2] dst[3] = aTwist[3][0] * src[0] + aTwist[3][1] * src[1] + aTwist[3][2] * src[2] + aTwist[3][3] * src[3] + aConstants[3]
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
aConstants – fixed size array of constant values, one per channel..
- Returns
-
NppStatus nppiColorTwist32f_8u_P3R_Ctx(const Npp8u *const pSrc[3], int nSrcStep, Npp8u *const pDst[3], int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned planar color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_P3R(const Npp8u *const pSrc[3], int nSrcStep, Npp8u *const pDst[3], int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 8-bit unsigned planar color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8u_IP3R_Ctx(Npp8u *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 8-bit unsigned planar in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place planar pixel format image pointer array, one pointer per plane.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8u_IP3R(Npp8u *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 8-bit unsigned planar in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place planar pixel format image pointer array, one pointer per plane.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_C1R_Ctx(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 8-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_C1R(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 8-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_C1IR_Ctx(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 8-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_C1IR(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 8-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_C2R_Ctx(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 8-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_C2R(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 8-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_C2IR_Ctx(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 8-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_C2IR(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 8-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_C3R_Ctx(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 8-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_C3R(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 8-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_C3IR_Ctx(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 8-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_C3IR(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 8-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_C4R_Ctx(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 8-bit signed color twist, with alpha copy.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is copied unmodified from the source pixel to the destination pixel.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_C4R(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 8-bit signed color twist, with alpha copy.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is copied unmodified from the source pixel to the destination pixel.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_C4IR_Ctx(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 8-bit signed in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is unmodified.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_C4IR(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 8-bit signed in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is unmodified.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_AC4R_Ctx(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 8-bit signed color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_AC4R(const Npp8s *pSrc, int nSrcStep, Npp8s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 8-bit signed color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_AC4IR_Ctx(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 8-bit signed in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_AC4IR(Npp8s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 8-bit signed in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_P3R_Ctx(const Npp8s *const pSrc[3], int nSrcStep, Npp8s *const pDst[3], int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 8-bit signed planar color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_P3R(const Npp8s *const pSrc[3], int nSrcStep, Npp8s *const pDst[3], int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 8-bit signed planar color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_8s_IP3R_Ctx(Npp8s *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 8-bit signed planar in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place planar pixel format image pointer array, one pointer per plane.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_8s_IP3R(Npp8s *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 8-bit signed planar in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place planar pixel format image pointer array, one pointer per plane.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_C1R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 16-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_C1R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 16-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_C1IR_Ctx(Npp16u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 16-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_C1IR(Npp16u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 16-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_C2R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 16-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_C2R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 16-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_C2IR_Ctx(Npp16u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 16-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_C2IR(Npp16u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 16-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_C3R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_C3R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit unsigned color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_C3IR_Ctx(Npp16u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_C3IR(Npp16u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit unsigned in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_AC4R_Ctx(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 16-bit unsigned color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_AC4R(const Npp16u *pSrc, int nSrcStep, Npp16u *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 16-bit unsigned color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_AC4IR_Ctx(Npp16u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 16-bit unsigned in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_AC4IR(Npp16u *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 16-bit unsigned in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_P3R_Ctx(const Npp16u *const pSrc[3], int nSrcStep, Npp16u *const pDst[3], int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit unsigned planar color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_P3R(const Npp16u *const pSrc[3], int nSrcStep, Npp16u *const pDst[3], int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit unsigned planar color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16u_IP3R_Ctx(Npp16u *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit unsigned planar in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place planar pixel format image pointer array, one pointer per plane.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16u_IP3R(Npp16u *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit unsigned planar in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place planar pixel format image pointer array, one pointer per plane.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_C1R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 16-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_C1R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 16-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_C1IR_Ctx(Npp16s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 16-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_C1IR(Npp16s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 16-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_C2R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 16-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_C2R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 16-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_C2IR_Ctx(Npp16s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 16-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_C2IR(Npp16s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 16-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_C3R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_C3R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit signed color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_C3IR_Ctx(Npp16s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_C3IR(Npp16s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit signed in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_AC4R_Ctx(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 16-bit signed color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_AC4R(const Npp16s *pSrc, int nSrcStep, Npp16s *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 16-bit signed color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_AC4IR_Ctx(Npp16s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 16-bit signed in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_AC4IR(Npp16s *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 16-bit signed in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not processed.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_P3R_Ctx(const Npp16s *const pSrc[3], int nSrcStep, Npp16s *const pDst[3], int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit signed planar color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_P3R(const Npp16s *const pSrc[3], int nSrcStep, Npp16s *const pDst[3], int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit signed planar color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16s_IP3R_Ctx(Npp16s *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit signed planar in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place planar pixel format image pointer array, one pointer per plane.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16s_IP3R(Npp16s *const pSrcDst[3], int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit signed planar in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place planar pixel format image pointer array, one pointer per plane.
nSrcDstStep – in place planar pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16f_C1R_Ctx(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 16-bit floating point color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16f_C1R(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 16-bit floating point color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16f_C1IR_Ctx(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 16-bit floating point in place color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16f_C1IR(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 16-bit floating point in place color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16f_C2R_Ctx(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 16-bit floating point color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16f_C2R(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 16-bit floating point color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16f_C2IR_Ctx(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 16-bit floating point in place color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16f_C2IR(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 16-bit floating point in place color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16f_C3R_Ctx(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit floating point color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16f_C3R(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit floating point color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16f_C3IR_Ctx(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 16-bit floating point in place color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16f_C3IR(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 16-bit floating point in place color twist.
An input color twist matrix with 32-bit floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16f_C4R_Ctx(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 16-bit floating point color twist, with alpha copy.
An input color twist matrix with 32-bit floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is copied unmodified from the source pixel to the destination pixel.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16f_C4R(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 16-bit floating point color twist, with alpha copy.
An input color twist matrix with 32-bit floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is copied unmodified from the source pixel to the destination pixel.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32f_16f_C4IR_Ctx(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 16-bit floating point in place color twist, not affecting Alpha.
An input color twist matrix with 32-bit floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not modified.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32f_16f_C4IR(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 16-bit floating point in place color twist, not affecting Alpha.
An input color twist matrix with 32-bit floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not modified.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist32fC_16f_C4R_Ctx(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[4][4], const Npp32f aConstants[4], NppStreamContext nppStreamCtx)
4 channel 16-bit floating point color twist with 4x4 matrix and constant vector addition.
An input 4x4 color twist matrix with 32-bit floating-point coefficient values with an additional 32-bit floating point constant vector addition is applied within ROI. For this particular version of the function the result is generated as shown below.
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3] * src[3] + aConstants[0] dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3] * src[3] + aConstants[1] dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3] * src[3] + aConstants[2] dst[3] = aTwist[3][0] * src[0] + aTwist[3][1] * src[1] + aTwist[3][2] * src[2] + aTwist[3][3] * src[3] + aConstants[3]
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
aConstants – fixed size array of constant values, one per channel..
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32fC_16f_C4R(const Npp16f *pSrc, int nSrcStep, Npp16f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[4][4], const Npp32f aConstants[4])
4 channel 16-bit floating point color twist with 4x4 matrix and constant vector addition.
An input 4x4 color twist matrix with 32-bit floating-point coefficient values with an additional 32-bit floating point constant vector addition is applied within ROI. For this particular version of the function the result is generated as shown below.
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3] * src[3] + aConstants[0] dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3] * src[3] + aConstants[1] dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3] * src[3] + aConstants[2] dst[3] = aTwist[3][0] * src[0] + aTwist[3][1] * src[1] + aTwist[3][2] * src[2] + aTwist[3][3] * src[3] + aConstants[3]
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
aConstants – fixed size array of constant values, one per channel..
- Returns
-
NppStatus nppiColorTwist32fC_16f_C4IR_Ctx(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[4][4], const Npp32f aConstants[4], NppStreamContext nppStreamCtx)
4 channel 16-bit floating point in place color twist with 4x4 matrix and an additional constant vector addition.
An input 4x4 color twist matrix with 32-bit floating-point coefficient values with an additional 32-bit floating point constant vector addition is applied within ROI. For this particular version of the function the result is generated as shown below.
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3] * src[3] + aConstants[0] dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3] * src[3] + aConstants[1] dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3] * src[3] + aConstants[2] dst[3] = aTwist[3][0] * src[0] + aTwist[3][1] * src[1] + aTwist[3][2] * src[2] + aTwist[3][3] * src[3] + aConstants[3]
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
aConstants – fixed size array of constant values, one per channel..
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist32fC_16f_C4IR(Npp16f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[4][4], const Npp32f aConstants[4])
4 channel 16-bit floating point in place color twist with 4x4 matrix and an additional constant vector addition.
An input 4x4 color twist matrix with 32-bit floating-point coefficient values with an additional 32-bit floating point constant vector addition is applied within ROI. For this particular version of the function the result is generated as shown below.
dst[0] = aTwist[0][0] * src[0] + aTwist[0][1] * src[1] + aTwist[0][2] * src[2] + aTwist[0][3] * src[3] + aConstants[0] dst[1] = aTwist[1][0] * src[0] + aTwist[1][1] * src[1] + aTwist[1][2] * src[2] + aTwist[1][3] * src[3] + aConstants[1] dst[2] = aTwist[2][0] * src[0] + aTwist[2][1] * src[1] + aTwist[2][2] * src[2] + aTwist[2][3] * src[3] + aConstants[2] dst[3] = aTwist[3][0] * src[0] + aTwist[3][1] * src[1] + aTwist[3][2] * src[2] + aTwist[3][3] * src[3] + aConstants[3]
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
aConstants – fixed size array of constant values, one per channel..
- Returns
-
NppStatus nppiColorTwist_32f_C1R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 32-bit floating point color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist_32f_C1R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 32-bit floating point color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist_32f_C1IR_Ctx(Npp32f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
1 channel 32-bit floating point in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist_32f_C1IR(Npp32f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
1 channel 32-bit floating point in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist_32f_C2R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 32-bit floating point color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist_32f_C2R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 32-bit floating point color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist_32f_C2IR_Ctx(Npp32f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
2 channel 32-bit floating point in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist_32f_C2IR(Npp32f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
2 channel 32-bit floating point in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist_32f_C3R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 32-bit floating point color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist_32f_C3R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 32-bit floating point color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist_32f_C3IR_Ctx(Npp32f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
3 channel 32-bit floating point in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist_32f_C3IR(Npp32f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
3 channel 32-bit floating point in place color twist.
An input color twist matrix with floating-point coefficient values is applied within ROI.
- Parameters
pSrcDst – in place packed pixel format image pointer.
nSrcDstStep – in place packed pixel format image line step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist_32f_C4R_Ctx(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 32-bit floating point color twist, with alpha copy.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is copied unmodified from the source pixel to the destination pixel.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
nppStreamCtx – Application Managed Stream Context.
- Returns
-
NppStatus nppiColorTwist_32f_C4R(const Npp32f *pSrc, int nSrcStep, Npp32f *pDst, int nDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4])
4 channel 32-bit floating point color twist, with alpha copy.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is copied unmodified from the source pixel to the destination pixel.
- Parameters
pSrc – Source-Image Pointer.
nSrcStep – Source-Image Line Step.
pDst – Destination-Image Pointer.
nDstStep – Destination-Image Line Step.
oSizeROI – Region-Of-Interest (ROI).
aTwist – The color twist matrix with floating-point coefficient values.
- Returns
-
NppStatus nppiColorTwist_32f_C4IR_Ctx(Npp32f *pSrcDst, int nSrcDstStep, NppiSize oSizeROI, const Npp32f aTwist[3][4], NppStreamContext nppStreamCtx)
4 channel 32-bit floating point in place color twist, not affecting Alpha.
An input color twist matrix with floating-point coefficient values is applied with in ROI. Alpha channel is the last channel and is not modified.
- Parameters