Remove binary edge objects
#include "dip_binary.h"
dip_Error dip_EdgeObjectsRemove ( in, out, connectivity )
binary
The function EdgeObjectsRemove removes those binary objects from in which are connected to the edges of the image. The connectivity of the objects is determined by connectivity. This function is a front-end to BinaryPropagation. It calls BinaryPropagation with no seed image and the edge pixels turned on. The result of the propagation is xor-ed with the input image. The connectivity parameter defines the metric, that is, the shape of the structuring element. 1 indicates city-block metric, or a diamond-shaped structuring element. 2 indicates chessboard metric, or a square structuring element. -1 and -2 indicate alternating connectivity and produce an octagonal structuring element. See The connectivity parameter for more information. The edge parameter specifies whether the border of the image should be treated as object (DIP_TRUE) or as background (DIP_FALSE).
See section 10.3, "Segmentation", in Fundamentals of Image Processing for a description of the edge object removal operation.
Data type | Name | Description |
dip_Image | in | Binary input image |
dip_Image | out | Output |
dip_int | connectivity | Pixel connectivity |
This function is only implemented for images with a dimension up to three.