Content deleted Content added
Line 3:
It is generally applicable only in [[2D computer graphics|2D]]. However, it can be used in [[3D computer graphics|3D]] through visible surface determination and with improved efficiency through [[Z-order]]ing.<ref>Foley, James, Andries van Dam, Steven Feiner, and John Hughes. "Computer Graphics: Principle and Practice". Addison-Wesley Publishing Company. Reading, Massachusetts: 1987. pages 689-693</ref>
==
[[image:Weiler-Atherton subdivision.svg|thumb|upright=1.2|Subdivision with the Weiler-Atherton algorithm]]
Before applying to any polygon, the algorithm requires several preconditions to be fulfilled.
Line 12:
- The algorithm can support holes (as counter-clockwise polygons wholly inside their parent polygon), but requires additional algorithms to decide which polygons are holes. Then, merging of polygons can be performed by a variant of the algorithm.
== The Algorithm ==
Two lists are created from the coordinates of each polygons A and B, where A is the clip region and B is the polygon to be clipped.
|