Searching contours [closed]

asked 2018-11-13 16:30:15 -0500

Gacsam gravatar image

updated 2018-11-15 07:02:45 -0500

Hi, I've been recently learning computer vision with opencv2 as part of my uni course. I'm trying to draw contours of an image, an apple in this case. The best result I have had is the image below, which is running the image through canny edge detection and then findContours on the result. When I attempted to use binary thresholding, I had only one half of the image contours, inverted binary resulted in the opposite half of the image. Anything other than CV_CHAIN_APPROX_NONE in findContours results with a completely black image, so I'd assume there are no contours found, but it looks like a approx_simple's description since the straight lines are blacked out. Is there a reason it works this way?

image description

Edit: fixed following the tutorial very closely this time

edit retag flag offensive reopen merge delete

Closed for the following reason question is not relevant or outdated by Gacsam
close date 2018-11-15 07:02:13.246280


please show, how you use findContours()

berak gravatar imageberak ( 2018-11-14 01:04:40 -0500 )edit