summaryrefslogtreecommitdiff
path: root/src/mesa/main/state.c
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2006-04-25 00:53:25 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2006-04-25 00:53:25 +0000
commit94b30dc390f1fdd526c080080830016fad3e2ee2 (patch)
tree92643c41eae15bcf373a9777ca04e73cfe46c7c3 /src/mesa/main/state.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/main/state.c')
-rw-r--r--src/mesa/main/state.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mesa/main/state.c b/src/mesa/main/state.c
index 761a45f2bd..34eb2c3b8a 100644
--- a/src/mesa/main/state.c
+++ b/src/mesa/main/state.c
@@ -881,9 +881,13 @@ update_arrays( GLcontext *ctx )
/* 6 */
if (ctx->VertexProgram._Enabled
- && ctx->Array.VertexAttrib[VERT_ATTRIB_SIX].Enabled) {
- min = MIN2(min, ctx->Array.VertexAttrib[VERT_ATTRIB_SIX]._MaxElement);
+ && ctx->Array.VertexAttrib[VERT_ATTRIB_COLOR_INDEX].Enabled) {
+ min = MIN2(min, ctx->Array.VertexAttrib[VERT_ATTRIB_COLOR_INDEX]._MaxElement);
}
+ else if (ctx->Array.Index.Enabled) {
+ min = MIN2(min, ctx->Array.Index._MaxElement);
+ }
+
/* 7 */
if (ctx->VertexProgram._Enabled
@@ -912,10 +916,6 @@ update_arrays( GLcontext *ctx )
}
}
- if (ctx->Array.Index.Enabled) {
- min = MIN2(min, ctx->Array.Index._MaxElement);
- }
-
if (ctx->Array.EdgeFlag.Enabled) {
min = MIN2(min, ctx->Array.EdgeFlag._MaxElement);
}