Wednesday, May 28, 2008

Canny's Two Thresholds

void cvCanny( const CvArr* image, CvArr* edges, double threshold1,double threshold2, int aperture_size=3 );

In the up sentence, the threshold1 is lower threshold, the other one is higher threshold. Canny edge detection contain three steps: First:
Gaussian filter...Smoothing the image and filter the noise..
find the edge strength by taking the gradient of the image.
Third: Use the two threshold to determine which pixel is edge.

If the edge gradient below the first threshold, it's set to zero(nonedge). If the magnitude of edge gradient is above the high threshold, it 's made
an edge. And if the edge gradient between lower and higher threshold, then it's set to zero unless there is a path from this pixel to another pixel that have
a edge gradient above higher threshold.

see more ""

No comments: