mesa: Fix assertions for block size handling in glCompressedTexSubImage2D.
authorEric Anholt <eric@anholt.net>
Thu, 1 Dec 2011 22:52:44 +0000 (14:52 -0800)
committerEric Anholt <eric@anholt.net>
Fri, 2 Dec 2011 23:28:44 +0000 (15:28 -0800)
commit079bb3fff7104782f2c921200e9a299c38a53ab6
treee5086d59f09cb4a1a5f51782905fdf888cbe88dd
parent1e0b6a90d78ed78eb9e22c65abd5af314142a844
mesa: Fix assertions for block size handling in glCompressedTexSubImage2D.

Anything of less than (bw, bh) size is possible when you consider
rectangular textures, and this code is (now) safe for those.  Even for
power-of-two textures, width could be 4 for FXT1 while not being
aligned to block size.

Fixes piglit compressedteximage GL_COMPRESSED_RGB_FXT1_3DFX

Reviewed-by: Brian Paul <brianp@vmware.com>
src/mesa/main/texstore.c