Polygon Clipping - Raster Graphics and Clipping
After considerate the idea of line clipping and its algorithms, we can currently extend the idea of line clipping to polygon clipping, since polygon is a surface enclosed through several lines. Hence, by considering the polygon like a set of line we can divide the trouble to line clipping and thus, the problem of polygon clipping is simplified.
However, it is to be noted that, clipping all edge separately via using a line clipping algorithm will specifically not generate a truncated polygon as one would suppose. Fairly, it would produce a set of line segments that are not connected as the polygon is exploded. In this lies the requirement to use a diverse clipping algorithm to output truncated although yet bounded regions from a polygon input. Sutherland-Hodgman algorithm is one of the standard methods utilized for clipping arbitrary shaped polygons along with a rectangular clipping window. It utilizes divide and conquer method for clipping the polygon.