summaryrefslogtreecommitdiff
path: root/src/mesa/tnl/t_vertex.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/tnl/t_vertex.c')
-rw-r--r--src/mesa/tnl/t_vertex.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/mesa/tnl/t_vertex.c b/src/mesa/tnl/t_vertex.c
index c8cfb6e106..8ae8e74648 100644
--- a/src/mesa/tnl/t_vertex.c
+++ b/src/mesa/tnl/t_vertex.c
@@ -681,7 +681,7 @@ static void generic_emit( GLcontext *ctx,
for (j = 0; j < count; j++) {
GLvector4f *vptr = VB->AttribPtr[a[j].attrib];
a[j].inputstride = vptr->stride;
- a[j].inputptr = (GLubyte *)STRIDE_4F(vptr->data, start * vptr->stride);
+ a[j].inputptr = ((GLubyte *)vptr->data) + start * vptr->stride;
a[j].emit = a[j].insert[vptr->size - 1];
}
@@ -921,7 +921,7 @@ void _tnl_get_attr( GLcontext *ctx, const void *vin,
for (j = 0; j < attr_count; j++) {
if (a[j].attrib == attr) {
- a[j].extract( &a[j], dest, vin );
+ a[j].extract( &a[j], dest, (GLubyte *)vin + a[j].vertoffset );
return;
}
}
@@ -979,6 +979,9 @@ GLuint _tnl_install_attrs( GLcontext *ctx, const struct tnl_attr_map *map,
else
vtx->attr[i].vertoffset = offset;
+/* fprintf(stderr, "%d: %s offset %d\n", i, */
+/* format_info[format].name, vtx->attr[i].vertoffset); */
+
offset += format_info[format].attrsize;
}