mesa: Fix glCompressedTexSubImage (and non-Sub) for height == 2 or 1.
authorEric Anholt <eric@anholt.net>
Thu, 1 Dec 2011 22:35:18 +0000 (14:35 -0800)
committerEric Anholt <eric@anholt.net>
Fri, 2 Dec 2011 23:28:44 +0000 (15:28 -0800)
commit1e0b6a90d78ed78eb9e22c65abd5af314142a844
treedbddf08294eabe837e7328f52368e8ebe57f9111
parentbda361e0d47a670f318664abcdf0a065bef22883
mesa: Fix glCompressedTexSubImage (and non-Sub) for height == 2 or 1.

Generally this code works with width and height aligned to compressed
blocks, but at the 2x2 and 1x1 levels of a square texture (or height <
bh in general), we were skipping uploading our single row of blocks.

Fixes piglit compressedteximage GL_COMPRESSED_RGBA_S3TC_DXT5_EXT.

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