Adds squared pixel values of a source image to floating-point pixel values of an accumulator image.
Case 1: In-place operation
IppStatus ippiAddSquare_<mod>(const Ipp<srcDatatype>* pSrc, int srcStep, Ipp32f* pSrcDst, int srcDstStep, IppiSize roiSize);
Supported values for mod:
8u32f_C1IR |
8s32f_C1IR |
16u32f_C1IR |
32f_C1IR |
Case 2: Masked in-place operation
IppStatus ippiAddSquare_<mod>(const Ipp<srcDatatype>* pSrc, int srcStep, const Ipp8u* pMask, int maskStep, Ipp32f* pSrcDst, int srcDstStep, IppiSize roiSize);
Supported values for mod:
8u32f_C1IMR |
8s32f_C1IMR |
16u32f_C1IMR |
32f_C1IMR |
pSrc1 |
Pointer to the source image ROI. |
srcStep |
Distance in bytes between starts of consecutive lines in the source image. |
pMask |
Pointer to the mask image. |
maskStep |
Distance in bytes between starts of consecutive lines in the mask image. |
pSrcDst |
Pointer to the destination (accumulator) image ROI. |
srcDstStep |
Distance in bytes between starts of consecutive lines in the accumulator image. |
roiSize |
Size of the image ROI in pixels. |
The function ippiAddSquare is declared in the ippcv.h file. It operates with ROI (see Regions of Interest in Intel IPP).
This function adds squared pixel values of the source image pSrc to floating-point pixel values of the accumulator image pSrcDst as follows:
pSrcDst(x,y) = pSrcDst(x,y) + pSrc(x,y)2
Addition of the squared pixel values in case of a masked operation is performed only if the respective mask value is nonzero; otherwise, the accumulator pixel value remains unchanged.
ippStsNoErr |
Indicates no error. Any other value indicates an error or a warning. |
ippStsNullPtrErr |
Indicates an error condition if any of the specified pointers is NULL. |
ippStsSizeErr |
Indicates an error when roiSize.width or roiSize.height is negative. |
ippStsStepErr |
Indicates an error when srcStep, maskStep, or srcDstStep is less than roiSize.width * <pixelSize>. |
ippStsNotEvenStepErr |
Indicates an error condition if one of step values for floating-point images cannot be divided by 4. |
Copyright © 2000 - 2011, Intel Corporation. All rights reserved.