You are here : matlabImage Processingbwareaopen

bwareaopen() - Image Processing

BW2 = bwareaopen(BW,P) removes
all connected components (objects) that have fewer than P pixels
from the binary image BW, producing another binary
image, BW2.  The default connectivity is 8 for
two dimensions, 26 for three dimensions, and conndef(ndims(BW),
'maximal') for higher dimensions. This operation is known
as an area opening. BW2 = bwareaopen(BW,P,conn) 
removes all connected components, where conn 
specifies the desired connectivity.Code Generation support:
Yes. MATLABĀ® Function Block support: No.


BW2 = bwareaopen(BW,P) exampleBW2 = bwareaopen(BW,P,conn)


CC = bwconncomp(BW, conn);

Output / Return Value


Alternatives / See Also