mesa/st: leave current query enabled during glBlitFramebuffer
authorIlia Mirkin <imirkin@alum.mit.edu>
Sat, 10 May 2014 14:25:29 +0000 (10:25 -0400)
committerIlia Mirkin <imirkin@alum.mit.edu>
Sun, 11 May 2014 23:26:31 +0000 (19:26 -0400)
Also make sure that pipe_blit_info gets zero'd out so that query isn't
accidentally left enabled.

Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: "10.2" <mesa-stable@lists.freedesktop.org>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
src/mesa/state_tracker/st_cb_blit.c
src/mesa/state_tracker/st_cb_readpixels.c
src/mesa/state_tracker/st_cb_texture.c

index a5a0d2d8d2649aab3ecabc9dfa5d92ba5c388585..9c33f4eb99c58f492de47140539a53018ddf0c0a 100644 (file)
@@ -187,6 +187,7 @@ st_BlitFramebuffer(struct gl_context *ctx,
    }
 
    blit.filter = pFilter;
+   blit.render_condition_enable = TRUE;
 
    if (mask & GL_COLOR_BUFFER_BIT) {
       struct gl_renderbuffer_attachment *srcAtt =
index b92147847e4296c7cbf80556ee2c99c68fe03dc6..3f7bbd9738cb33310a29fa08e139472d24ab1567 100644 (file)
@@ -165,6 +165,7 @@ st_readpixels(struct gl_context *ctx, GLint x, GLint y,
       goto fallback;
    }
 
+   memset(&blit, 0, sizeof(blit));
    blit.src.resource = src;
    blit.src.level = strb->surface->u.tex.level;
    blit.src.format = src_format;
index 97bba8b7da59f38c663f8c7462269da3e99121d5..aa6b05f0b6018287c55f368aa9aceb21fa130d33 100644 (file)
@@ -765,6 +765,7 @@ st_TexSubImage(struct gl_context *ctx, GLuint dims,
    _mesa_unmap_teximage_pbo(ctx, unpack);
 
    /* Blit. */
+   memset(&blit, 0, sizeof(blit));
    blit.src.resource = src;
    blit.src.level = 0;
    blit.src.format = src_format;
@@ -998,6 +999,7 @@ st_GetTexImage(struct gl_context * ctx,
       height = 1;
    }
 
+   memset(&blit, 0, sizeof(blit));
    blit.src.resource = src;
    blit.src.level = texImage->Level;
    blit.src.format = src_format;