Image dilation
imout = imdilate(imin,se)
Input image
Structure element
Output image
The function dilates the source image using the specified structuring element that determines the shape of a pixel neighborhood over which the maximum is taken.
a = zeros(10,10); a(4:7,4:7) = 1; se = imcreatese('rect',3,3); b = imdilate(a,se); disp(b);