<< Morphological Operations Morphological Operations imblackhat >>

IPCV >> Morphological Operations > bwborder

bwborder

Find border for an image

Syntax

outm = bwborder(inm, conn)

Parameters

inm :

Source Image (must be in binary)

conn :

4 or 8 neighbourhood

outm :

Output image (in double)

Description

Extracts contours from binary images, by detecting which pixel valued 1 has at least one neighbor valued 0. conn is 4 or 8 dependig if the detection is to be made in 4 or 8-neighborhood. The final border is 8-connected if 4-neighbors are used, and 4-connected if 8-neighbors are used.

Examples

inm = imread(fullpath(getIPCVpath() + "/images/big_sq.png"));
outm = bwborder(im2bw(inm,0.5), 4);
imshow(outm);

See also

Authors


Report an issue
<< Morphological Operations Morphological Operations imblackhat >>