Forum

Make Contour remember IDs of lost contours

hi

by default contour gives a contour that disapears and then apears again automatically an new id that is +1 from the highest currently existing ids.

is it possible to change that behaviour in the sourcecode so that the contourtracker remembers the id of a contour and use that id again when a contour apear again?

i dont have the skills to do that, maybe someone has?

cheers ele…

jep, should be possible with functions offered by openCV, which let you compare contours. but i’d say it is not an easy task for a beginner.

Have to say I’ve come across exactly that problem as well, it would be a useful addition if anyone fancies the task!