arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1207.3502cs.CG
收藏

复杂多边形点在多边形中的一种简单正确的奇偶算法

A Simple and Correct Even-Odd Algorithm for the Point-in-Polygon Problem for Complex Polygons

Michael Galetzka, Patrick O. Glauner

摘要:

在计算机图形学、计算机游戏和地理信息学的许多应用中,都需要确定一个点是否在多边形中。执行此检查容易出错,因为有许多特殊情况需要考虑。这尤其适用于边缘彼此相交从而产生孔洞的复杂多边形。本文提出了一个简单的奇偶算法来解决这个问题的复杂多边形在线性时间,并证明其正确性的所有可能的点和多边形。我们还提供了这个算法的例子和实施说明。

英文摘要:

Determining if a point is in a polygon or not is used by a lot of applications in computer graphics, computer games and geoinformatics. Implementing this check is error-prone since there are many special cases to be considered. This holds true in particular for complex polygons whose edges intersect each other creating holes. In this paper we present a simple even-odd algorithm to solve this problem for complex polygons in linear time and prove its correctness for all possible points and polygons. We furthermore provide examples and implementation notes for this algorithm.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑