diff options
author | Ian Romanick <ian.d.romanick@intel.com> | 2009-12-14 16:16:26 -0800 |
---|---|---|
committer | Ian Romanick <ian.d.romanick@intel.com> | 2009-12-14 16:30:53 -0800 |
commit | b90f7f3ad324b1e4c39e334cdeb9556c3eb808ab (patch) | |
tree | 19b0ce94eef3cc45db906f2e4fe803ff9369c4be /src/mesa/drivers/dri/i965/brw_wm_surface_state.c | |
parent | f4de0b176d282a75ee3f47547667feea31e0d3f3 (diff) |
i965: Use current draw buffer instead of drawable visual to get alpha bits
Use the currently bound draw buffer instead of the visual from the
drawable used to create the context. This cause problems generating
mipmaps for an RGBA texture in an RGB context.
This fixes the failure in piglit's glsl-lod-bias test reported in bug #25614.
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_wm_surface_state.c')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c index 3f9b1fbfdc..8335e5a650 100644 --- a/src/mesa/drivers/dri/i965/brw_wm_surface_state.c +++ b/src/mesa/drivers/dri/i965/brw_wm_surface_state.c @@ -581,7 +581,7 @@ brw_update_renderbuffer_surface(struct brw_context *brw, /* As mentioned above, disable writes to the alpha component when the * renderbuffer is XRGB. */ - if (ctx->Visual.alphaBits == 0) + if (ctx->DrawBuffer->Visual.alphaBits == 0) key.color_mask[3] = GL_FALSE; key.color_blend = (!ctx->Color._LogicOpEnabled && |