summaryrefslogtreecommitdiff
path: root/src/mesa/state_tracker/st_draw.c
diff options
context:
space:
mode:
authorBrian <brian.paul@tungstengraphics.com>2007-10-24 14:35:40 -0600
committerBrian <brian.paul@tungstengraphics.com>2007-10-24 14:35:40 -0600
commit40a0b053f78acd0a08f6876518b8e9301480431f (patch)
tree6ca70655441fd94a8518880d6d1da19eee7634a6 /src/mesa/state_tracker/st_draw.c
parent11ce6244a79106c592364b30434b6ddade3fd6bb (diff)
Revert "Undo indexOffset change (I think, git???)"
This reverts commit 11ce6244a79106c592364b30434b6ddade3fd6bb.
Diffstat (limited to 'src/mesa/state_tracker/st_draw.c')
-rw-r--r--src/mesa/state_tracker/st_draw.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/mesa/state_tracker/st_draw.c b/src/mesa/state_tracker/st_draw.c
index 50251a816b..fbf7713f58 100644
--- a/src/mesa/state_tracker/st_draw.c
+++ b/src/mesa/state_tracker/st_draw.c
@@ -197,7 +197,7 @@ st_draw_vbo(GLcontext *ctx,
/* indexed primitive */
struct gl_buffer_object *bufobj = ib->obj;
struct pipe_buffer_handle *indexBuf = NULL;
- unsigned indexSize, indexOffset, i;
+ unsigned indexSize, i;
switch (ib->type) {
case GL_UNSIGNED_INT:
@@ -218,19 +218,17 @@ st_draw_vbo(GLcontext *ctx,
/* elements/indexes are in a real VBO */
struct st_buffer_object *stobj = st_buffer_object(bufobj);
winsys->buffer_reference(winsys, &indexBuf, stobj->buffer);
- indexOffset = (unsigned) ib->ptr;
}
else {
/* element/indicies are in user space memory */
indexBuf = winsys->user_buffer_create(winsys,
(void *) ib->ptr,
ib->count * indexSize);
- indexOffset = 0;
}
/* draw */
for (i = 0; i < nr_prims; i++) {
- pipe->draw_elements(pipe, indexBuf, indexSize, indexOffset,
+ pipe->draw_elements(pipe, indexBuf, indexSize,
prims[i].mode, prims[i].start, prims[i].count);
}