Abstract
Polygon clipping is of great importance in computer graphics. One of the popular algorithms to clip a polygon is Cohan—Sutherland Hodgeman algorithm which is based on line clipping. Cohan—Sutherland Hodgeman algorithm clips the polygon against the given rectangular clip window with the help of line clipping method. Cohan—Sutherland algorithm requires traversing the polygon in anti clockwise direction (positive orientation). In this work we propose an efficient polygon clipping algorithm against a rectangular clip window. Proposed algorithm uses parametric representation of polygon edges. Using the concept of point clipping, we can find required intersection points of edges of polygon with clip window boundaries. Well suited numerical illustrations are used to explain the proposed polygon clipping method. The proposed algorithm is computationally less expensive and comprehensive.
Similar content being viewed by others
References
D Cohen. Incremental methods for computer graphics, PhD Thesis, University of Harvard, Massachusetts, 1969.
Y D Liang, B A Barsky. An analysis and algorithms for polygon clipping, CACM 26, 1983: 868–876.
Y D Liang, B A Barsky. A new concept and method for line clipping, ACM Transactions on Graphics, 1984, 3(1): 1–22.
M Cyrus, J Beck. Generalized two and three-dimensional clipping, Computers and Graphics, 1978, 3(1): 23–28.
M Rappaport. An efficient algorithm for line and polygon clipping, The Visual Computer, 1991, 7(1): 19–28.
V Skala. An efficient algorithm for line clipping by convex polygon, Computers and Graphics, 1993, 17(4): 417–421.
V Skala. O (lg N) line clipping algorithm in E2, Computers and Graphics, 1994, 18(4): 517–424.
K R Wijeweera, S R Kodituwakku, M P Chamikara. A novel and efficient approach for line segment clipping against a convex polygon, Ruhuna Journal of Science, 2019, 10(2): 161–173.
K Schutte. An edge labelling approach to concave polygon clipping, ACM Transactions on Graphics, 1995: 1–10.
E L Foster, K Hormann, R T Popa. Clipping simple polygons with degenerate intersections, Computers and Graphics, 2019, X(2).
G Greiner, K Hormann. Efficient clipping of arbitrary polygons, ACM Transactions on Graphics, 1998, 17(2): 71–83.
D H Kim, M J Kim. An extension of polygon clipping to resolve degenerate cases, Computer Aided Design Appl., 2006, 3: 447–456.
Y K Liu, X Q Wang, S Z Bao, M GomboŠi, B Žalik. An algorithm for polygon clipping, and for determining polygon intersections and unions, Computers and Geosciences, 2007, 33: 589–598.
S P Raja. Line and Polygon Clipping Techniques on Natural Images: A Mathematical Solution and Performance Evaluation, International Journal of Image and Graphics, 2019, 19(2).
T M Nicholl, T Lee, R A Nicholl. An efficient new algorithm for 2D line clipping: Its development and analysis, in Proc SIGGRAPH’ 87, Comput Graph, 1987, 21(4): 253–262.
E Mamatha, C Reddy, K Anand. An Efficient Line Clipping Algorithm in 2D Space, The International Arab Journal of Information Technology, 2019, 16(5).
D Matthes, V Drakopoulos. Another Simple but Faster Method for 2D Line Clipping, International Journal of Computer Graphics and Animation, 2019, 9(1/2/3).
S C Dimri. A Simple and Efficient Algorithm for Line and Polygon Clipping in 2-D Computer Graphics, International Journal of Computer Applications, 2015, 127(3).
M Sharma, J Kaur. An Improved Polygon Clipping Algorithm Based on Affine Transformation, S C Satapathy, et al, in Proceedings of the Second International Conference on Computer and Communication Technologies, Advances in Intelligent Systems and Computing, 2016, 379.
D Yang, S Chen, Q Yang, Y Hu. A Clipping Algorithm on Vector Graphics Based on Nonintersect Polygon Boundary, IEEE, 2019, 854–859.
T Joshi, P Badoni, A Aggarwal. Modification of Weiler-Atherton Algorithm to Address Loose Polygons, Journal of Scientific and Industrial Research, 2019, 78: 771–774.
M Cao, H Zhang, C Zhou, Y Sun, H Yu. Vector Circle Clipping Algorithm Based on Polygon Window of Hexagonal Grid System, IOP Conf Series: Journal of Physics: Conf Series, 2019, 1288(012006).
M Zhang, C L Sabharwal. An Efficient Implementation of Parametric Line And Polygon Clipping Algorithm, ACMSAC’02, 2002, 11–14.
Author information
Authors and Affiliations
Corresponding author
Rights and permissions
About this article
Cite this article
Dimri, S.C., Tiwari, U.K. & Ram, M. An efficient algorithm to clip a 2D-polygon against a rectangular clip window. Appl. Math. J. Chin. Univ. 37, 147–158 (2022). https://doi.org/10.1007/s11766-022-4556-0
Received:
Revised:
Published:
Issue Date:
DOI: https://doi.org/10.1007/s11766-022-4556-0