morphErode
[ XITE Reference Manual | XITE home ]
Name
morphErode - morphological grayscale erode on an image.
Syntax
morphErode <-a | -b> <struct_element> <inimage> <outimage>
Description
morphErode calculates the morphological operation
erode on the inimage with a structuring element given
by struct_element (in combination with option -a or
-b). The resulting image is sent to outimage.
The actual calculation is performed with the expression:
outband(x,y) = min[inband(x+i,y+j)-B(-i,-j)]
with i and j inside the structuring element B
and (0,0) as the center pixel of B.
Restrictions
Input images must be of the following types:
-
inimage
- Unsigned byte.
-
struct_element
- With option -a: Ascii characters (numbers) describing the
structuring element. With option -b: BIFF image with pixel
type signed short.
Options
-
-a struct_element
- struct_element is an ascii file which contains the
structuring element. See ascii2biff(1) for file format.
-
-b struct_element
- struct_element is a BIFF image which contains the
structuring element.
See also
morphErode(3), morphDilate(1), morphOpen(1), morphClose(1),
ascii2biff(1)
Return value
0 : OK
1 : Usage message
2 : Illegal number of arguments
3 : No structuring element
Author
Martin Torpe Lie, BLAB, Ifi, UiO
Examples
morphErode ~blab/img/mona.img mona.img -a filter.txt
morphErode ~blab/img/mona.img mona.img -b filter.img
Id
$Id: morphErode.c,v 1.23 1997/03/18 12:09:16 svein Exp $