summaryrefslogtreecommitdiff
path: root/src/mesa/main/fbobject.c
diff options
context:
space:
mode:
authorKeith Whitwell <keithw@vmware.com>2009-04-21 16:55:57 +0100
committerJosé Fonseca <jfonseca@vmware.com>2009-04-22 09:03:17 +0100
commit009749b4a8c3ec54f47f3f85552e5ae275ab6ae6 (patch)
treed41cb5a617bc77b10917cb8a444b59e0053d862b /src/mesa/main/fbobject.c
parentc1a3b852807fb160f0cd246c1364b7336b4b947e (diff)
mesa: protect driver.flush() with FLUSH_CURRENT
Need to do this to ensure vbo code unmaps its buffers before calling the driver, which may be sitting on top of a memory manager which objects to firing commands from a mapped buffer.
Diffstat (limited to 'src/mesa/main/fbobject.c')
-rw-r--r--src/mesa/main/fbobject.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c
index 151e29053a..9c5a5908a2 100644
--- a/src/mesa/main/fbobject.c
+++ b/src/mesa/main/fbobject.c
@@ -692,7 +692,7 @@ _mesa_BindRenderbufferEXT(GLenum target, GLuint renderbuffer)
return;
}
- FLUSH_VERTICES(ctx, _NEW_BUFFERS);
+ FLUSH_CURRENT(ctx, _NEW_BUFFERS);
/* The above doesn't fully flush the drivers in the way that a
* glFlush does, but that is required here:
*/
@@ -1187,8 +1187,7 @@ _mesa_BindFramebufferEXT(GLenum target, GLuint framebuffer)
return;
}
- FLUSH_VERTICES(ctx, _NEW_BUFFERS);
-
+ FLUSH_CURRENT(ctx, _NEW_BUFFERS);
if (ctx->Driver.Flush) {
ctx->Driver.Flush(ctx);
}
@@ -1269,7 +1268,7 @@ _mesa_DeleteFramebuffersEXT(GLsizei n, const GLuint *framebuffers)
GET_CURRENT_CONTEXT(ctx);
ASSERT_OUTSIDE_BEGIN_END(ctx);
- FLUSH_VERTICES(ctx, _NEW_BUFFERS);
+ FLUSH_CURRENT(ctx, _NEW_BUFFERS);
/* The above doesn't fully flush the drivers in the way that a
* glFlush does, but that is required here:
*/
@@ -1507,7 +1506,7 @@ framebuffer_texture(GLcontext *ctx, const char *caller, GLenum target,
}
}
- FLUSH_VERTICES(ctx, _NEW_BUFFERS);
+ FLUSH_CURRENT(ctx, _NEW_BUFFERS);
/* The above doesn't fully flush the drivers in the way that a
* glFlush does, but that is required here:
*/
@@ -1688,7 +1687,7 @@ _mesa_FramebufferRenderbufferEXT(GLenum target, GLenum attachment,
}
- FLUSH_VERTICES(ctx, _NEW_BUFFERS);
+ FLUSH_CURRENT(ctx, _NEW_BUFFERS);
/* The above doesn't fully flush the drivers in the way that a
* glFlush does, but that is required here:
*/
@@ -1769,7 +1768,7 @@ _mesa_GetFramebufferAttachmentParameterivEXT(GLenum target, GLenum attachment,
}
}
- FLUSH_VERTICES(ctx, _NEW_BUFFERS);
+ FLUSH_CURRENT(ctx, _NEW_BUFFERS);
/* The above doesn't fully flush the drivers in the way that a
* glFlush does, but that is required here:
*/