softpipe: fix depth testing problems
authorBrian Paul <brianp@vmware.com>
Fri, 19 Feb 2010 00:00:10 +0000 (17:00 -0700)
committerBrian Paul <brianp@vmware.com>
Fri, 19 Feb 2010 00:00:10 +0000 (17:00 -0700)
commitae7a7026c77c68748fedb60e5deb7649e894da40
tree52c07c752622bfa63fc8321ecd8e114313209b02
parent0c728030ed76d8b79876b8606cb0486bff96750c
softpipe: fix depth testing problems

The optimized Z-test functions assumed that the array of incoming quads
are adjacent, but that's not always true.  The fragment shader can cull
intermediate quads, for example.

Now these Z-test functions can cope with non-adjacent quads.  A little bit
of performance is probably lost, but it's probably not worth worring about.

This fixes broken glBitmap() Z testing, among other things.

(cherry picked from commit d437d905e6924ebc05ec9efe87e1e2c48d75bc13)
src/gallium/drivers/softpipe/sp_quad_depth_test.c