diff options
Diffstat (limited to 'src/gallium/drivers')
-rw-r--r-- | src/gallium/drivers/softpipe/sp_prim_vbuf.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/gallium/drivers/softpipe/sp_prim_vbuf.c b/src/gallium/drivers/softpipe/sp_prim_vbuf.c index ddfe56f73a..c60249dbfb 100644 --- a/src/gallium/drivers/softpipe/sp_prim_vbuf.c +++ b/src/gallium/drivers/softpipe/sp_prim_vbuf.c @@ -543,15 +543,17 @@ sp_vbuf_draw_arrays(struct vbuf_render *vbr, uint start, uint nr) } static void -sp_vbuf_so_info(struct vbuf_render *vbr, uint buffer, uint vertices) +sp_vbuf_so_info(struct vbuf_render *vbr, uint primitives, uint vertices) { struct softpipe_vbuf_render *cvbr = softpipe_vbuf_render(vbr); struct softpipe_context *softpipe = cvbr->softpipe; + unsigned i; - softpipe->so_target.so_count[buffer] += vertices; + for (i = 0; i < softpipe->so_target.num_buffers; ++i) { + softpipe->so_target.so_count[i] += vertices; + } - softpipe->so_stats.num_primitives_written = - vertices / u_vertices_per_prim(cvbr->prim); + softpipe->so_stats.num_primitives_written = primitives; softpipe->so_stats.primitives_storage_needed = vertices * 4 /*sizeof(float|int32)*/ * 4 /*x,y,z,w*/; } |