Painter's algorithm: Difference between revisions

Content deleted Content added
Cyclical Overlapping: Variants: Added subheaders to variant and created a new section for other computer graphics algorithms
Other computer graphics algorithms: Removed beginning sentence. Will create See also section
Line 50:
 
== Other computer graphics algorithms ==
Numerous computer graphics algorithms have also been proposed in the field of [[computational geometry]].
 
The flaws of painter's algorithm led to the development of [[Z-buffering|Z-buffer]] techniques, which can be viewed as a development of the painter's algorithm by resolving depth conflicts on a pixel-by-pixel basis, reducing the need for a depth-based rendering order. Even in such systems, a variant of the painter's algorithm is sometimes employed. As Z-buffer implementations generally rely on fixed-precision depth-buffer registers implemented in hardware, there is scope for visibility problems due to rounding error. These are overlaps or gaps at joints between polygons. To avoid this, some graphics engine implementations "overrender"{{Citation needed|date=January 2008}}, drawing the affected edges of both polygons in the order given by the painter's algorithm. This means that some pixels are actually drawn twice (as in the full painter's algorithm), but this happens on only small parts of the image and has a negligible performance effect.