Tutorial

Blurring an Image Using
ippiFilterBoxBorder

A box blur of an image is a filtering process that sets each pixel in a destination image to the average value of all pixels of a source image in a rectangular neighborhood of the specified mask size. This operation has the effect of blurring or smoothing of the source image.
Intel IPP
ippiFilterBoxBorder
function implements box blurring of an image. Before calling the processing function, you need to allocate memory for the work buffer. You can get the required memory size for the specified parameters using the
ippiFilterBoxBorderGetBufferSize
auxiliary function. The code extract below demonstrates how to use the box blur functionality of Intel IPP:
… IppStatus status = ippStsNoErr; IppiSize maskSize = {3,3}; IppiSize srcSize = {0}; Ipp8u* pBuffer = NULL; Ipp8u* pSrc = NULL; Ipp8u* pDst = NULL; int srcStep, dstStep; … /* assigning parameters */ … /* Get work buffer size */ status = ippiFilterBoxBorderGetBufferSize(srcSize, maskSize, ipp8u, 3, &bufSize); pBuffer = ippsMalloc_8u(bufSize); /* Filter the image */ if (status >= ippStsNoErr) status = ippiFilterBoxBorder_8u_C3R(pSrc, srcStep, pDst, dstStep, srcSize, maskSize, ippBorderRepl, NULL, pBuffer); if (pBuffer) ippsFree(pBuffer); …
For more information about the
ippiFilterBoxBorder
API and auxiliary functions, refer to the
Intel IPP Developer Reference
.

Product and Performance Information

1

Intel's compilers may or may not optimize to the same degree for non-Intel microprocessors for optimizations that are not unique to Intel microprocessors. These optimizations include SSE2, SSE3, and SSSE3 instruction sets and other optimizations. Intel does not guarantee the availability, functionality, or effectiveness of any optimization on microprocessors not manufactured by Intel. Microprocessor-dependent optimizations in this product are intended for use with Intel microprocessors. Certain optimizations not specific to Intel microarchitecture are reserved for Intel microprocessors. Please refer to the applicable product User and Reference Guides for more information regarding the specific instruction sets covered by this notice.

Notice revision #20110804