Allocates and initializes morphology state structure for erosion or dilation operation.
IppStatus ippiMorphologyInitAlloc_<mod>(int roiWidth, const Ipp8u* pMask, IppiSize maskSize, IppiPoint anchor, IppiMorphState** ppState);
Supported values for mod:
8u_C1R | 32f_C1R |
8u_C3R | 32f_C3R |
8u_C4R | 32f_C4R |
roiWidth |
Maximal width of the image ROI in pixels, that can be processed using the allocated structure. |
pMask |
Pointer to the mask. |
maskSize |
Size of the mask in pixels. |
anchor |
Coordinates of the anchor cell. |
ppState |
Pointer to the pointer to the morphology state structure. |
The function ippiMorphologyInitAlloc is declared in the ippcv.h file. It operates with ROI (see Regions of Interest in Intel IPP).
This function allocates memory, initializes the morphology state structure and returns the pointer ppState to it. It is used by the functions DilateBorderReplicate and ErodeBorderReplicate that perform morphological operations on the source image pixels corresponding to non-zero values of the structuring element pMask. The anchor cell anchor is positioned in the arbitrary point in the structuring element and is used for positioning the structuring element.
Example “Using the Morphlogy Functions” shows how to use the function ippiMorphologyInitAlloc_8u_C1R.
The structure can be used to process an image with ROI that does not exceed the specified maximum width roiWidth.
ippStsNoErr |
Indicates no error. Any other value indicates an error or a warning. |
ippStsNullPtrErr |
Indicates an error when one of the specified pointers is NULL. |
ippStsSizeErr |
Indicates an error condition if maskSize has a field with a zero or negative value, or if roiWidth is less than 1. |
ippStsAnchorErr |
Indicates an error if anchor is outside the mask. |
Copyright © 2000 - 2011, Intel Corporation. All rights reserved.