Module: Mesa
Branch: master
Commit: 6c3f6968911e0bb3256e91b070166d3da78a4775
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=6c3f6968911e0bb3256e91b070166d3da78a4775

Author: Eric Anholt <[email protected]>
Date:   Wed Jun 17 20:53:27 2009 -0700

i965: Fix up texture layout for small things with wide pitches (tiled)

We were packing according to the pitch, while the hardware appears to base
it on the base level width.

With this and the previous commit, fbo-cubemap now matches untiled behavior.

---

 src/mesa/drivers/dri/i965/brw_tex_layout.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/mesa/drivers/dri/i965/brw_tex_layout.c 
b/src/mesa/drivers/dri/i965/brw_tex_layout.c
index 5c54558..67d8d96 100644
--- a/src/mesa/drivers/dri/i965/brw_tex_layout.c
+++ b/src/mesa/drivers/dri/i965/brw_tex_layout.c
@@ -69,7 +69,7 @@ GLboolean brw_miptree_layout(struct intel_context *intel,
         pack_y_pitch = ALIGN(mt->height0, align_h);
       }
 
-      pack_x_pitch = mt->pitch;
+      pack_x_pitch = width;
       pack_x_nr = 1;
 
       for (level = mt->first_level ; level <= mt->last_level ; level++) {

_______________________________________________
mesa-commit mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to