- Irregular Z-buffer
The irregular Z-buffer is an algorithm designed to solve the
visibility problem in real-time 3-d computer graphics. It is related to the classicalZ-buffer in that it maintains a depth value for each image sample and uses these to determine which geometric elements of a scene are visible. The key difference, however, between the classical Z-buffer and the irregular Z-buffer is that the latter allows arbitrary placement of image samples in the image plane, whereas the former requires samples to be arranged in a regular grid.These depth samples are explicitly stored in a two-dimensional spatial data structure. During
rasterization , triangles are projected onto the image plane as usual, and the data structure is queried to determine which samples overlap each projected triangle. Finally, for each overlapping sample, the standard Z-compare and (conditional) frame buffer update are performed.Implementation
The classical rasterization algorithm projects each
polygon onto the image plane, and determines which sample points from a regularly-spaced set lie inside the projected polygon. Since the locations of these samples (i.e. pixels) are implicit, this determination can be made by testing the edges against the implicit grid of sample points. If, however the locations of the sample points are irregularly spaced and cannot be computed from a formula, then this approach does not work. The irregular Z-buffer solves this problem by storing sample locations explicitly in a two-dimensional spatialdata structure , and later querying this structure to determine which samples lie within a projected triangle. This latter step is referred to as "irregular rasterization". Although the particular data structure used may vary from implementation to implementation, the two studied approaches are thekd-tree , and a grid of linked lists. A balanced kd-tree implementation has the advantage that it guarantees O(log(N)) access. Its chief disadvantage is that parallel construction of the kd-tree may be difficult, and traversal requires expensive branch instructions. The grid of lists has the advantage that it can be implemented more effectively on GPU hardware, which is designed primarily for the classical Z-buffer.Applications
The irregular Z-buffer can be used for any application which requires visibility calculations at arbitrary locations in the image plane. It has been shown to be particularly adept at
shadow mapping , an image space algorithm for rendering hard shadows. In addition to shadow rendering, potential applications include adaptiveanti-aliasing , jittered sampling, andenvironment mapping .External links
* [http://www.tacc.utexas.edu/~cburns/papers/izb-tog.pdf The Irregular Z-Buffer: Hardware Acceleration for Irregular Data Structures]
* [http://www.cs.utexas.edu/ftp/pub/techreports/tr04-09.pdf The Irregular Z-Buffer And Its Application to Shadow Mapping]
* [http://www.tml.hut.fi/~timo/publications/aila2004egsr_paper.pdf Alias-Free Shadow Maps]
Wikimedia Foundation. 2010.