I am trying to use findcontours () in OpenCV in the image below.
findContours(img, contours, hierarchy, CV_RETR_TREE, CV_CHAIN_APPROX_NONE, cvPoint(0,0) );
When I make this query: contours.size()it returns 18, so for each circle there are 2 circuits. Circles - how do you see 1-pixel thickness, like 2 contours? This is one for the outside and one for the inside, if so, how can I make this function detect only one path for each circle? I thought the outline was defined as a connected sequence of pixels with a thickness of 1 pixel.
contours.size()
, , , , - . , , - , . , , ( )
findContours
, CV_RETR_EXTERNAL CV_RETR_TREE. , ,
, , ...
findContours , , .
- findContoours . , .