summaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2009-03-18 10:22:05 -0600
committerBrian Paul <[email protected]>2009-03-18 10:24:19 -0600
commit0b0e2159f2e9e9278c058d06387948f54e537d08 (patch)
tree78edc279b5443d05e03cd076cdf284d54825305f /src/mesa/state_tracker
parenta0509f7d28765c6ef8546eafba94aec46d9e7ed3 (diff)
st: need to free/realloc pipe texture when we're handed image level > last_level
Fixes progs/tests/tri-fbo-tex-mip.c
Diffstat (limited to 'src/mesa/state_tracker')
-rw-r--r--src/mesa/state_tracker/st_cb_texture.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_cb_texture.c b/src/mesa/state_tracker/st_cb_texture.c
index f94713abd1d..df169b163e0 100644
--- a/src/mesa/state_tracker/st_cb_texture.c
+++ b/src/mesa/state_tracker/st_cb_texture.c
@@ -467,6 +467,7 @@ st_TexImage(GLcontext * ctx,
*/
if (stObj->pt) {
if (stObj->teximage_realloc ||
+ level > stObj->pt->last_level ||
(stObj->pt->last_level == level &&
stObj->pt->target != PIPE_TEXTURE_CUBE &&
!st_texture_match_image(stObj->pt, &stImage->base,