summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/depth.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main/depth.c')
-rw-r--r--src/mesa/main/depth.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mesa/main/depth.c b/src/mesa/main/depth.c
index 6c60222096a..aca471a06c8 100644
--- a/src/mesa/main/depth.c
+++ b/src/mesa/main/depth.c
@@ -162,13 +162,15 @@ void _mesa_init_depth( GLcontext * ctx )
ctx->Depth.Mask = GL_TRUE;
ctx->Depth.OcclusionTest = GL_FALSE;
+ /* XXX this is now per-framebuffer state */
+#if 00
/* Z buffer stuff */
if (ctx->Visual.depthBits == 0) {
/* Special case. Even if we don't have a depth buffer we need
* good values for DepthMax for Z vertex transformation purposes
* and for per-fragment fog computation.
*/
- ctx->DepthMax = 1 << 16;
+ ctx->DepthMax = (1 << 16) - 1;
ctx->DepthMaxF = (GLfloat) ctx->DepthMax;
}
else if (ctx->Visual.depthBits < 32) {
@@ -183,4 +185,5 @@ void _mesa_init_depth( GLcontext * ctx )
ctx->DepthMaxF = (GLfloat) ctx->DepthMax;
}
ctx->MRD = 1.0; /* Minimum resolvable depth value, for polygon offset */
+#endif
}