| [Top] [Up] [Prev] [Next] | [Up] [Basic Concepts] [Demonstrations] [Functions] | SDC Morphology Toolbox V1.1 15Jan02 |
y = mmsupcanon( f, Iab, theta, DIRECTION ) f: Binary image (logical uint8). Iab: Interval. theta: Degrees of rotation: 45, 90, or 180. Default: 45.DIRECTION: String. 'CLOCKWISE' or ' ANTI-CLOCKWISE' Default: "CLOCKWISE".y: Binary image (logical uint8). mmsupcanon creates the image y by computing the union of transformations of the image f by sup-generating operators. These hit-miss operators are characterized by rotations (in the clockwise or anti-clockwise direction) of theta degrees of the interval Iab.f=mmbinary(uint8([ 0 0 1 0 0 1 1; 0 1 0 0 1 0 0; 0 0 0 1 1 0 0])) f = 0 0 1 0 0 1 1 0 1 0 0 1 0 0 0 0 0 1 1 0 0 i=mmendpoints; mmintershow(i) ans = . . . 0 1 0 0 0 0 g=mmsupcanon(f,i) g = 0 0 1 0 0 0 1 0 1 0 0 0 0 0 0 0 0 1 1 0 0 |
a=mmbinary(mmreadgray('gear.tif')); Warning: Converting image from binary uint8 to uint8. b=mmsupcanon(a,mmendpoints); mmshow(a); mmshow(mmdil(b));
|

function y=mmsupcanon_equ( f, Iab, theta, DIRECTION )
y = uint8(zeros(size(f)));
y = mmunion(y,mmsupgen(f, Iab));
alpha = theta;
while alpha < 360
Irot = mminterot( Iab, alpha, DIRECTION );
y = mmunion(y,mmsupgen(f, Irot));
alpha = alpha + theta;
end; | [Top] [Up] [Prev] [Next] | [Up] [Basic Concepts] [Demonstrations] [Functions] |
|
| Copyright (c) 1998-2002 by SDC Information Systems | ||