diff options
Diffstat (limited to 'src/mesa/state_tracker/st_cb_bitmap.c')
-rw-r--r-- | src/mesa/state_tracker/st_cb_bitmap.c | 16 |
1 files changed, 5 insertions, 11 deletions
diff --git a/src/mesa/state_tracker/st_cb_bitmap.c b/src/mesa/state_tracker/st_cb_bitmap.c index ef44a08859c..66d7cbf8e6a 100644 --- a/src/mesa/state_tracker/st_cb_bitmap.c +++ b/src/mesa/state_tracker/st_cb_bitmap.c @@ -417,17 +417,11 @@ setup_bitmap_vertex_data(struct st_context *st, } /* put vertex data into vbuf */ - { - char *buf = pipe_buffer_map(pipe->screen, - st->bitmap.vbuf, - PIPE_BUFFER_USAGE_CPU_WRITE); - - memcpy(buf + st->bitmap.vbuf_slot * sizeof st->bitmap.vertices, - st->bitmap.vertices, - sizeof st->bitmap.vertices); - - pipe_buffer_unmap(pipe->screen, st->bitmap.vbuf); - } + pipe_buffer_write(pipe->screen, + st->bitmap.vbuf, + st->bitmap.vbuf_slot * sizeof st->bitmap.vertices, + sizeof st->bitmap.vertices, + st->bitmap.vertices); return st->bitmap.vbuf_slot++ * sizeof st->bitmap.vertices; } |