summaryrefslogtreecommitdiffstats
path: root/src/mesa/tnl/t_vb_light.c
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2006-04-25 00:53:25 +0000
committerBrian Paul <[email protected]>2006-04-25 00:53:25 +0000
commit94b30dc390f1fdd526c080080830016fad3e2ee2 (patch)
tree92643c41eae15bcf373a9777ca04e73cfe46c7c3 /src/mesa/tnl/t_vb_light.c
parent5bdc6fdebc0ab59a888fba15136eb4a0ee2790e1 (diff)
Put color index attribute into the 6th attribute slot.
Update a lot of loops, conditionals to use the _TNL_FIRST/LAST_* values instead of specific vertex attributes. Remove the EdgeFlagv function from the GLvertexformat struct.
Diffstat (limited to 'src/mesa/tnl/t_vb_light.c')
-rw-r--r--src/mesa/tnl/t_vb_light.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/tnl/t_vb_light.c b/src/mesa/tnl/t_vb_light.c
index 4d360007a46..47c5b400aae 100644
--- a/src/mesa/tnl/t_vb_light.c
+++ b/src/mesa/tnl/t_vb_light.c
@@ -135,7 +135,7 @@ prepare_materials(GLcontext *ctx,
* update_materials(), above, that'll actually copy the vertex color to
* the material attribute(s).
*/
- for (i = _TNL_ATTRIB_MAT_FRONT_AMBIENT ; i < _TNL_ATTRIB_INDEX ; i++) {
+ for (i = _TNL_FIRST_MAT; i <= _TNL_LAST_MAT; i++) {
if (VB->AttribPtr[i]->stride) {
const GLuint j = store->mat_count++;
const GLuint attr = i - _TNL_ATTRIB_MAT_FRONT_AMBIENT;
@@ -251,7 +251,7 @@ static GLboolean run_lighting( GLcontext *ctx,
VB->AttribPtr[_TNL_ATTRIB_COLOR0] = VB->ColorPtr[0];
VB->AttribPtr[_TNL_ATTRIB_COLOR1] = VB->SecondaryColorPtr[0];
- VB->AttribPtr[_TNL_ATTRIB_INDEX] = VB->IndexPtr[0];
+ VB->AttribPtr[_TNL_ATTRIB_COLOR_INDEX] = VB->IndexPtr[0];
return GL_TRUE;
}