st/mesa: fix guessing the base level size
authorMarek Olšák <maraeo@gmail.com>
Sun, 11 Nov 2012 15:08:56 +0000 (16:08 +0100)
committerMarek Olšák <maraeo@gmail.com>
Mon, 12 Nov 2012 20:37:31 +0000 (21:37 +0100)
commitc06258dd0297e1fe7910f48a59aa0de79029ce39
treef339f39e9a4c4354581c13da4bd52a21f2faa998
parent985f2aec4a2ca74f6612f34ce0887eafcc163e08
st/mesa: fix guessing the base level size

It was pretty broken with array textures, where the array size (height or
depth depending on the target) shouldn't be magnified.

The guessing also doesn't fail with 1D and cube textures.

NOTE: This is a candidate for the stable branches.

Reviewed-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
src/mesa/state_tracker/st_cb_texture.c