Next: Warnock's Algorithm
Up: Hidden Surface Removal
Previous: Backface Culling
- Painter's Algorithm
-
- Idea: Draw polygons as an oil painter might:
The farthest one first.
- Sort polygons on farthest z
- Resolve ambiguities where z's overlap
- Scan convert from largest z to smallest z
\
- Since closest drawn last, it will be on top (and therefore
it will be seen).
- Need all polygons at once in order to sort.
- Painter's Algorithm
- Z overlap
- Some cases are easy:
\
- But other cases are nasty!
(have to split polygons)
- algorithm
- Lots of subtle detail
CS488/688: Introduction to Interactive Computer Graphics
University of Waterloo
Computer Graphics Lab
cs488@cgl.uwaterloo.ca