summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2012-04-18 08:31:45 -0600
committerBrian Paul <[email protected]>2012-04-18 08:34:48 -0600
commit8ec18dfc1af43ef1f74c3f28c87e11da815f1958 (patch)
tree80a17c342506770a963bc33afc53836ba1c43283 /src
parent168a3b8627861fbb2786839f7e276de82f883e42 (diff)
svga: flush drawing before clearing
We don't normally clear immediately after drawing something. But as it was, the drawing would incorrectly appear after the clear. Fixes piglit clear-varray-2.0 failure. Reviewed-by: José Fonseca <[email protected]>
Diffstat (limited to 'src')
-rw-r--r--src/gallium/drivers/svga/svga_pipe_clear.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/gallium/drivers/svga/svga_pipe_clear.c b/src/gallium/drivers/svga/svga_pipe_clear.c
index 89a66f65e7c..d2fcdd39868 100644
--- a/src/gallium/drivers/svga/svga_pipe_clear.c
+++ b/src/gallium/drivers/svga/svga_pipe_clear.c
@@ -115,6 +115,9 @@ svga_clear(struct pipe_context *pipe, unsigned buffers,
SVGA_DBG(DEBUG_DMA, "clear sid %p\n",
svga_surface(svga->curr.framebuffer.cbufs[0])->handle);
+ /* flush any queued prims (don't want them to appear after the clear!) */
+ svga_hwtnl_flush_retry(svga);
+
ret = try_clear( svga, buffers, color, depth, stencil );
if (ret == PIPE_ERROR_OUT_OF_MEMORY) {