summaryrefslogtreecommitdiff
path: root/src/mesa
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2008-08-18 13:15:09 -0600
committerBrian Paul <brian.paul@tungstengraphics.com>2008-08-18 13:18:01 -0600
commit145a45e9d6807add8229f1fc9c63fbb6951b1b88 (patch)
treefaa3ccea70c769c9af817663f864cfa8d2f2adff /src/mesa
parent235981d8719aa7f67bfe547bf96e5343020e0373 (diff)
gallium: fix do_flip bug on glCopyTexImage / surface_copy() path
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/state_tracker/st_cb_texture.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_cb_texture.c b/src/mesa/state_tracker/st_cb_texture.c
index cf194a937f..6177ac63f0 100644
--- a/src/mesa/state_tracker/st_cb_texture.c
+++ b/src/mesa/state_tracker/st_cb_texture.c
@@ -1098,6 +1098,10 @@ st_copy_texsubimage(GLcontext *ctx,
stImage->face, stImage->level,
destZ,
PIPE_BUFFER_USAGE_GPU_WRITE);
+ if (do_flip)
+ srcY = strb->surface->height - srcY - height;
+
+ /* for surface_copy(), y=0=top, always */
pipe->surface_copy(pipe,
do_flip,
/* dest */