浏览全部资源
扫码关注微信
湖北工业大学
收稿日期:2007-11-16,
修回日期:2008-01-21,
网络出版日期:2008-06-25,
纸质出版日期:2008-06-25
移动端阅览
孙贤斌,尹杰,李德华,肖本林. 基于法线方向的点包容检测[J]. 光学精密工程, 2008,16(6):1122-1126
Sun Xian-bin, Yin Jie, Xiao Benlin. Point in Polygon Testing based on Normal Direction[J]. Optics and precision engineering, 2008, 16(6): 1122-1126.
孙贤斌,尹杰,李德华,肖本林. 基于法线方向的点包容检测[J]. 光学精密工程, 2008,16(6):1122-1126 DOI:
Sun Xian-bin, Yin Jie, Xiao Benlin. Point in Polygon Testing based on Normal Direction[J]. Optics and precision engineering, 2008, 16(6): 1122-1126. DOI:
过待定点作一射线,此射线可能与多边形的某几条边有交点,从待定点向这条边的两端点作两个向量,求这两向量的法线方向,对法线方向进行计数。若法线方向为正向,将计数器加1;若法线方向为反向,将计数器减1。求待定点与每条相交边的两向量的法线方向并计数,当法线方向的正反次数相同时,待定点在多边形外,否则在多边形内。此算法避免了某些其他算法的错误,计算量很小,简单易行。通过编写程序计算验证表明,算法简单有效、稳定可靠,对简单多边形、自相交多边形及带孔多边形等多类情况同样适用。
Two vectors compose of point and edge of polygon was defined
the normal direction of these two vectors was calculated
the normal direction is the reference for testing. A line was drawn through the point
there are some crossing points between line and some edges of polygon
the normal direction of point and these edges was calculated
if the number of positive normal and negative normal is same
the point is outside the polygon
otherwise the point is inside the polygon. This method didn’t make mistake like half-line method
and it is sample than other methods. The computation is decreased. It is proved be an effective and simple robust algorithm by programming
and it is suitable for most case self-intersection polygon.
0
浏览量
15
下载量
2
CSCD
关联资源
相关文章
相关作者
相关机构