Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

findContours when image is cut off (part of the object in the image)

I have the following image (many immages of that kind, backgroud vary from image to image, might be dark, or light)

image description

i use canny, then dilate, then I find largest contour with findContours and drawContour (CV_FILLED). This is my result:

image description

the problem is that there is only part of the object in the image (part of the leg), and it seems that in the place where the photo is cut, contour is not closed. How i can somehow close the contour where the image is cut ?

Im not publishing my code here becouse i use binding for node, https://github.com/peterbraden/node-opencv I ask my question here, becouse this is much bigger community!

findContours when image is cut off (part of the object in the image)

I have the following image (many immages of that kind, backgroud vary from image to image, might be dark, or light)

image description image description

i use canny, then dilate, then I find largest contour with findContours and drawContour (CV_FILLED). This is my result:

image description image description

the problem is that there is only part of the object in the image (part of the leg), and it seems that in the place where the photo is cut, contour is not closed. How i can somehow close the contour where the image is cut ?

Im not publishing my code here becouse i use binding for node, https://github.com/peterbraden/node-opencv I ask my question here, becouse this is much bigger community!