An efficient algorithm for line and polygon clipping

Ari Rappoport*

*Corresponding author for this work

Research output: Contribution to journalArticlepeer-review

28 Scopus citations

Abstract

We present an algorithm for clipping a polygon or a line against a convex polygonal window. The algorithm demonstrates the practicality of various ideas from computational geometry. It spends O(log p) time on each edge of the clipped polygon, where p is the number of window edges, while the Sutherland-Hodgman algorithm spends O(p) time per edge. Theoretical and experimental analyses show that the constants involved are small enough to make the algorithm competitive even for windows with four edges. The algorithm enables image-space clipping against windows whose boundaries are convex spline curves. The paper contains detailed pseudo-code implementation of the algorithm and an adaptation of the simulation of simplicity method for handling degenerate cases.

Original languageAmerican English
Pages (from-to)19-28
Number of pages10
JournalVisual Computer
Volume7
Issue number1
DOIs
StatePublished - Jan 1991

Keywords

  • Computational geometry
  • Line clipping
  • Polygon algorithms
  • Polygon elipping
  • Simulation of simplicity

Fingerprint

Dive into the research topics of 'An efficient algorithm for line and polygon clipping'. Together they form a unique fingerprint.

Cite this