summaryrefslogtreecommitdiff
path: root/src/mesa/drivers
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2009-06-09 15:07:39 -0600
committerBrian Paul <brianp@vmware.com>2009-06-09 15:07:39 -0600
commita03b349153660e449daf4f56d750f1caef23b1a5 (patch)
tree2367ebb756f721b47c11dcf25459c6636687c9e6 /src/mesa/drivers
parent29c79a03a42365b4bf828c81ab8676e3e42cfbaf (diff)
i965: added intelFlush() call in intel_get_tex_image()
Fixes the render-to-texture test in progs/tests/getteximage.c
Diffstat (limited to 'src/mesa/drivers')
-rw-r--r--src/mesa/drivers/dri/intel/intel_tex_image.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_tex_image.c b/src/mesa/drivers/dri/intel/intel_tex_image.c
index 7339015d75..e9a3823078 100644
--- a/src/mesa/drivers/dri/intel/intel_tex_image.c
+++ b/src/mesa/drivers/dri/intel/intel_tex_image.c
@@ -628,6 +628,12 @@ intel_get_tex_image(GLcontext * ctx, GLenum target, GLint level,
struct intel_context *intel = intel_context(ctx);
struct intel_texture_image *intelImage = intel_texture_image(texImage);
+ /* If we're reading from a texture that has been rendered to, need to
+ * make sure rendering is complete.
+ * We could probably predicate this on texObj->_RenderToTexture
+ */
+ intelFlush(ctx);
+
/* Map */
if (intelImage->mt) {
/* Image is stored in hardware format in a buffer managed by the