Filter
Filters an image using a general rectangular kernel.
Syntax
IppStatus ippiFilter_64f_C1R(const Ipp64f*
pSrc
, int
srcStep
, Ipp64f*
pDst
, int
dstStep
, IppiSize
dstRoiSize
, const Ipp64f*
pKernel
, IppiSize
kernelSize
, IppiPoint
anchor
, Ipp8u*
pBuffer
);
Include Files
ippi.h
Domain Dependencies
Headers:
ippcore.h
,
ippvm.h
,
ipps.h
Libraries:
ippcore.lib
,
ippvm.lib
,
ipps.lib
Parameters
- pSrc
- Pointer to the source image ROI.
- srcStep
- Distance, in bytes, between the starting points of consecutive lines in the source image.
- pDst
- Pointer to the destination image ROI.
- dstStep
- Distance, in bytes, between the starting points of consecutive lines in the destination image.
- dstRoiSize
- Size of the source and destination ROI in pixels.
- pKernel
- Pointer to the kernel values.
- kernelSize
- Size of the rectangular kernel in pixels.
- anchor
- Anchor cell specifying the rectangular kernel alignment with respect to the position of the input pixel.
- pBuffer
- Pointer to the work buffer.
Description
This function operates with ROI.
The
ippiFilter
function uses the general rectangular kernel of kernelSize
size to filter an image ROI. This function sums the products of the kernel coefficients pKernel
and pixel values taken over the source pixel neighborhood defined by kernelSize
and anchor
. The anchor cell is specified by its coordinates anchor.x
and anchor.y
in the coordinate system associated with the bottom right corner of the kernel.Kernel coefficients are used in inverse order. The sum is written to the destination pixel.
To ensure valid operation when image boundary pixels are processed, the application should correctly define additional border pixels (see Borders in Neighborhood Operations).
This function
requires a temporary work buffer. Before using this function flavor, you need to compute the buffer size using the ippiFilterGetBufSize
function.Return Values
- ippStsNoErr
- Indicates no error. Any other value indicates an error.
- ippStsNullPtrErr
- Indicates an error whenpSrc,pDst, orpKernelisNULL.
- ippStsSizeErr
- Indicates an error whendstRoiSizeorkernelSizehas a field with a zero or negative value.
- ippStsDivisorErr
- Indicates an error when thedivisorhas a zero value.
- ippStsStepErr
- Indicates an error when:
- srcStepis less than(roiSize.width+kernelSize.width)*sizeof(Ipp64f)
- dstStepis less thanroiSize.width*sizeof(Ipp64f)