intelCopyBuffer: Remove incorrect intel_fb->pf_current_page tests.
authorMichel Dänzer <michel@tungstengraphics.com>
Thu, 15 Feb 2007 17:33:53 +0000 (18:33 +0100)
committerMichel Dänzer <michel@tungstengraphics.com>
Tue, 20 Feb 2007 18:15:44 +0000 (19:15 +0100)
intel_get_rb_region already takes the current page into account.

This would result in broken rendering when multiple 3D windows are visible
and the pages are reversed.

src/mesa/drivers/dri/i915tex/intel_blit.c

index e33d28307649af166af028c943f4257de5beb187..640c73e3551133f4f7ad5bc9449840de9e868e08 100644 (file)
@@ -184,25 +184,12 @@ noschedule:
            OUT_BATCH((pbox->y1 << 16) | pbox->x1);
            OUT_BATCH((pbox->y2 << 16) | pbox->x2);
 
-           if (intel_fb->pf_current_page == 0)
-              OUT_RELOC(frontRegion->buffer,
-                        DRM_BO_FLAG_MEM_TT | DRM_BO_FLAG_WRITE,
-                        DRM_BO_MASK_MEM | DRM_BO_FLAG_WRITE, 0);
-           else
-              OUT_RELOC(backRegion->buffer,
-                        DRM_BO_FLAG_MEM_TT | DRM_BO_FLAG_WRITE,
-                        DRM_BO_MASK_MEM | DRM_BO_FLAG_WRITE, 0);
+           OUT_RELOC(frontRegion->buffer, DRM_BO_FLAG_MEM_TT | DRM_BO_FLAG_WRITE,
+                     DRM_BO_MASK_MEM | DRM_BO_FLAG_WRITE, 0);
            OUT_BATCH((pbox->y1 << 16) | pbox->x1);
            OUT_BATCH(BR13 & 0xffff);
-
-           if (intel_fb->pf_current_page == 0)
-              OUT_RELOC(backRegion->buffer,
-                        DRM_BO_FLAG_MEM_TT | DRM_BO_FLAG_READ,
-                        DRM_BO_MASK_MEM | DRM_BO_FLAG_READ, 0);
-           else
-              OUT_RELOC(frontRegion->buffer,
-                        DRM_BO_FLAG_MEM_TT | DRM_BO_FLAG_READ,
-                        DRM_BO_MASK_MEM | DRM_BO_FLAG_READ, 0);
+           OUT_RELOC(backRegion->buffer, DRM_BO_FLAG_MEM_TT | DRM_BO_FLAG_READ,
+                     DRM_BO_MASK_MEM | DRM_BO_FLAG_READ, 0);
 
            ADVANCE_BATCH();
         }