diff options
author | José Fonseca <[email protected]> | 2010-01-21 12:13:27 -0800 |
---|---|---|
committer | José Fonseca <[email protected]> | 2010-01-21 15:18:40 -0800 |
commit | 0bc885188464446dd94542e0af15f3985dcdf684 (patch) | |
tree | 049612a0690389cfbdb3d69ec70464a580fb462d /src/gallium/drivers/svga | |
parent | 8410f7cde30cc1170ae266cf3a0eb7e0e37c454a (diff) |
svga: Avoid synchronization issues when doing SW TNL.
Diffstat (limited to 'src/gallium/drivers/svga')
-rw-r--r-- | src/gallium/drivers/svga/svga_swtnl_backend.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/gallium/drivers/svga/svga_swtnl_backend.c b/src/gallium/drivers/svga/svga_swtnl_backend.c index cfbdcf2554c..aafb3e26b0b 100644 --- a/src/gallium/drivers/svga/svga_swtnl_backend.c +++ b/src/gallium/drivers/svga/svga_swtnl_backend.c @@ -122,7 +122,9 @@ svga_vbuf_render_map_vertices( struct vbuf_render *render ) char *ptr = (char*)pipe_buffer_map(screen, svga_render->vbuf, PIPE_BUFFER_USAGE_CPU_WRITE | - PIPE_BUFFER_USAGE_FLUSH_EXPLICIT); + PIPE_BUFFER_USAGE_FLUSH_EXPLICIT | + PIPE_BUFFER_USAGE_DISCARD | + PIPE_BUFFER_USAGE_UNSYNCHRONIZED); return ptr + svga_render->vbuf_offset; } @@ -264,8 +266,8 @@ svga_vbuf_render_draw( struct vbuf_render *render, svga_render->ibuf_offset = 0; } - pipe_buffer_write(screen, svga_render->ibuf, - svga_render->ibuf_offset, 2 * nr_indices, indices); + pipe_buffer_write_nooverlap(screen, svga_render->ibuf, + svga_render->ibuf_offset, 2 * nr_indices, indices); /* off to hardware */ |