0

I want to find if one polygon is entirely included in or overlaps entirely with another. This question has a proposed algorithm, but as noted in the comment section some of the edge cases are not handled. Specifically in my case, I may have a situation like in this image:

enter image description here

All vertices of the red rectangle are shared with vertices of the black polygon. What is an efficient algorithm to find this case?

Toivo Säwén
  • 1,905
  • 2
  • 17
  • 33

1 Answers1

0

How about the "Algorithm 1" on page 13 in the following paper? It is algorithm whether a point is inside, outside or on a polygon.

https://www.researchgate.net/publication/328261365_Optimal_Reliable_Point-in-Polygon_Test_and_Differential_Coding_Boolean_Operations_on_Polygons

akio.tanaka
  • 154
  • 4