summaryrefslogtreecommitdiffstats
path: root/src/mesa/pipe
diff options
context:
space:
mode:
authorBrian <[email protected]>2007-08-11 21:19:04 +0100
committerBrian <[email protected]>2007-08-11 21:19:04 +0100
commit5d42fdb9b70a53938cd29d7ebeaa4b9cedd2e8e3 (patch)
tree03c223b51e649e3383a2e46923ee18b2585837d2 /src/mesa/pipe
parente209ca866dc1787b9eeece6ae3b53e1e47811d5f (diff)
mt->pitch must be at least 16 because of 64-byte alignment in sp_region.c (fix that someday)
Diffstat (limited to 'src/mesa/pipe')
-rw-r--r--src/mesa/pipe/softpipe/sp_tex_layout.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mesa/pipe/softpipe/sp_tex_layout.c b/src/mesa/pipe/softpipe/sp_tex_layout.c
index 37969c84de7..bd5f5e930da 100644
--- a/src/mesa/pipe/softpipe/sp_tex_layout.c
+++ b/src/mesa/pipe/softpipe/sp_tex_layout.c
@@ -116,6 +116,12 @@ sp_miptree_layout_2d( struct pipe_mipmap_tree *mt )
GLuint height = mt->height0;
mt->pitch = mt->width0;
+ /* XXX FIX THIS:
+ * we use alignment=64 bytes in sp_region_alloc(). If we change
+ * that, change this too.
+ */
+ if (mt->pitch < 16)
+ mt->pitch = 16;
/* May need to adjust pitch to accomodate the placement of
* the 2nd mipmap. This occurs when the alignment