I need to solve a contour detection problem. I define it as follows.

A contour detection is to recognize the outer rim of the given neighbor areas.

OK. So I have a txt file that defines the area geometry with their corner (boundary) points. Points have coordinates. With this, the need is to find the contour.

Please check the image in attachment to understand better.

I would like to use an...