In a more general sense, morphological operations involve an image
called the object of interest
and a kernel element
called the structuring element
. The image and structuring element could be in any number of
dimensions, but the most common use is with a 2D binary image, or with a 3D gray scale image.
is most often a square
or a circle, but it could be of any shape. Just like in convolution,
is a kernel or template with an anchor
"Dilation and Erosion of
shows dilation and
erosion of object
. In the figure,
is rectangular with an anchor point at
upper left shown as a dark square.