摘要
提出了一个基于扫描带的任意多边形窗口线裁剪算法。首先确定裁剪窗口所有顶点对于被裁剪直线段的位置关系,然后生成过顶点的扫描线,及时修改由相邻两条扫描线所构成的扫描带结构数据,增加每条扫描带中位于被裁剪直线段左侧的裁剪窗口的边界线数。最后,根据左侧边界线数的奇偶性,确定相应直线段的可见性,并最终实现任意多边形窗口的直线段裁剪过程。
A scan strip based algorithm for line clipping against arbitrary polygonal windows is proposed. Firstly, vertices of all polygons are located against the line to be clipped. Then, scan lines through vertices are created and correlative strip data are momentarily changed. The edge number of polygons left to the line to be clipped in the same strip is increased. Finally, the visibility of clipped line is determined by the parity of the number of polygon edges left to the clipped line.
出处
《工程图学学报》
CSCD
北大核心
2005年第2期35-40,共6页
Journal of Engineering Graphics
关键词
计算机图形学
线裁剪
扫描线
扫描带
computer graphics
line clipping
scan line
scan strip