radeon: Always initialize front and back renderbuffers if present
authorNicolai Hähnle <nhaehnle@gmail.com>
Mon, 1 Jun 2009 20:17:07 +0000 (22:17 +0200)
committerNicolai Hähnle <nhaehnle@gmail.com>
Sat, 27 Jun 2009 16:16:49 +0000 (18:16 +0200)
This fixes an assertion in glReadPixels from the front buffer.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
src/mesa/drivers/dri/radeon/radeon_common_context.c

index eb0e5b35e5ecc6decc6b9f01c4034efecd8eb730..009859fecaa0e2f40685f321cb289b817f0a08e0 100644 (file)
@@ -487,8 +487,7 @@ radeon_update_renderbuffers(__DRIcontext *context, __DRIdrawable *drawable)
                struct radeon_renderbuffer *stencil_rb;
 
                i = 0;
-               if ((radeon->is_front_buffer_rendering || !draw->color_rb[1])
-                       && draw->color_rb[0]) {
+               if (draw->color_rb[0]) {
                        attachments[i++] = __DRI_BUFFER_FRONT_LEFT;
                        attachments[i++] = radeon_bits_per_pixel(draw->color_rb[0]);
                }