摘要
通过判断多边形窗口顶点相对于裁剪线段所在直线的区域分布,明确窗口的哪些边与裁剪线段所在直线相交;再通过判断裁剪线段两端点相对于这些多边形窗口相交边的区域分布,最后确定裁剪线段与多边形窗口的实际交点。避免大量不必要的求交运算和其他复杂的辅助操作。实验结果表明:新算法提高了裁剪效率,对各种情况都能快速、正确地得到结果。
The edges of the polygonal window that intersects with the line that the clipping line segment lies can be determined by region distributing of the endpoints of the polygonal window relative to the line. At last, the true intersection of the clipping line segment and the polygonal window can be determined by region distributing of the two endpoints of the clipping line segment relative to the intersected edge of the polygonal window. A lot of needless intersection calculations and complicated assisting operators are avoided. The experimental results prove that the new algorithm further improves the clipping efficiency, and can deal with all kinds of situations easily and correctly.
出处
《科学技术与工程》
2009年第16期4833-4835,4843,共4页
Science Technology and Engineering
关键词
计算机图形学
多边形窗口
线裁剪
点关于直线区域分布
computer graphics polygonal window line clipping point distributing about line region