summaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker/st_draw.c
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2010-06-05 19:32:29 +0200
committerBrian Paul <[email protected]>2010-07-20 11:53:43 -0600
commit5ed6627ceb82845a7b578419b3cd4168ad0106d3 (patch)
treef0a197d8ab531e2fffff51f05b7d82e6693a4fe7 /src/mesa/state_tracker/st_draw.c
parent691c1fb074144395aa441b3102923d8f92136c37 (diff)
st/mesa: implement and advertise GL_ARB_draw_elements_base_vertex
Signed-off-by: Brian Paul <[email protected]>
Diffstat (limited to 'src/mesa/state_tracker/st_draw.c')
-rw-r--r--src/mesa/state_tracker/st_draw.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/mesa/state_tracker/st_draw.c b/src/mesa/state_tracker/st_draw.c
index 7fdaff45f76..5821da4889d 100644
--- a/src/mesa/state_tracker/st_draw.c
+++ b/src/mesa/state_tracker/st_draw.c
@@ -695,7 +695,8 @@ st_draw_vbo(GLcontext *ctx,
unsigned prim = translate_prim(ctx, prims[i].mode);
if (u_trim_pipe_prim(prims[i].mode, &vcount)) {
- pipe->draw_range_elements(pipe, indexBuf, indexSize, 0,
+ pipe->draw_range_elements(pipe, indexBuf, indexSize,
+ prims[i].basevertex,
min_index, max_index, prim,
prims[i].start + indexOffset, vcount);
}
@@ -710,7 +711,7 @@ st_draw_vbo(GLcontext *ctx,
if (prims[i].num_instances == 1) {
pipe->draw_elements(pipe, indexBuf,
indexSize,
- 0, /* indexBias */
+ prims[i].basevertex,
prim,
prims[i].start + indexOffset,
vcount);
@@ -718,7 +719,7 @@ st_draw_vbo(GLcontext *ctx,
else {
pipe->draw_elements_instanced(pipe, indexBuf,
indexSize,
- 0, /* indexBias */
+ prims[i].basevertex,
prim,
prims[i].start + indexOffset,
vcount,