diff options
author | Brian <[email protected]> | 2007-09-11 09:24:45 -0600 |
---|---|---|
committer | Brian <[email protected]> | 2007-09-11 09:25:49 -0600 |
commit | 791f12880f54d52ca8b86ed288cee889e2f6a2de (patch) | |
tree | 4a5f68a3d6c626d7a6b05e8f3ba99d1ef2c5e943 /src | |
parent | 7aa7373a64d3abae993dfce55190cdf88a1b85cf (diff) |
Update depth test state when binding new framebuffer object
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/drivers/dri/i915tex/intel_buffers.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i915tex/intel_buffers.c b/src/mesa/drivers/dri/i915tex/intel_buffers.c index 15d02f8e2cf..78fb720b6b9 100644 --- a/src/mesa/drivers/dri/i915tex/intel_buffers.c +++ b/src/mesa/drivers/dri/i915tex/intel_buffers.c @@ -1124,6 +1124,15 @@ intel_draw_buffer(GLcontext * ctx, struct gl_framebuffer *fb) ctx->Driver.Enable(ctx, GL_STENCIL_TEST, ctx->Stencil.Enabled); } + /* + * Update depth test state + */ + if (ctx->Depth.Test && fb->Visual.depthBits > 0) { + ctx->Driver.Enable(ctx, GL_DEPTH_TEST, GL_TRUE); + } + else { + ctx->Driver.Enable(ctx, GL_DEPTH_TEST, GL_FALSE); + } /** ** Release old regions, reference new regions |