crossing
[ XITE Reference Manual | XITE home ]
Name
crossing - find zero crossing or any other crossing
Syntax
#include <xite/convolve.h>
int crossing( IBAND iband, IBAND oband, int t );
Description
Can be used to find zero crossing of second derivative,
laplace. Can also be used to determine any other kind
of crossing. Pixels below or equal to t are set if the pixel
to the right or below is above t, pixels above t are
set if the pixel to the right or below is below or equal to
t. Pixels that are "set" are set to the maximum absolute
difference of the two neighbours, to indicate the strength
of the edge.
IF (crossing t)
out(x,y) = MAX(ABS(in(x,y)-in(x+1,y)),
ABS(in(x,y)-in(x,y+1)))
ELSE
out(x,y) = 0
Identical iband and oband arguments are allowed.
Restrictions
iband and oband must have pixel type unsigned byte.
Return value
0 => ok
1 => bad pixel type input band
2 => bad pixel type output band
See also
crossing(1), contour(3)
Author
Tor Lønnestad, BLAB, Ifi, UiO
Id
$Id: crossing.c,v 1.24 1997/01/16 15:53:28 svein Exp $