aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast_setup
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/swrast_setup
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/swrast_setup')
-rw-r--r--src/mesa/swrast_setup/ss_context.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/mesa/swrast_setup/ss_context.c b/src/mesa/swrast_setup/ss_context.c
index 0ce81e0487f..99cd7b5a33b 100644
--- a/src/mesa/swrast_setup/ss_context.c
+++ b/src/mesa/swrast_setup/ss_context.c
@@ -133,6 +133,9 @@ _swsetup_RenderStart( GLcontext *ctx )
if (RENDERINPUTS_TEST( index_bitset, _TNL_ATTRIB_COLOR1 ))
EMIT_ATTR( _TNL_ATTRIB_COLOR1, EMIT_4CHAN_4F_RGBA, specular);
+ if (RENDERINPUTS_TEST( index_bitset, _TNL_ATTRIB_COLOR_INDEX ))
+ EMIT_ATTR( _TNL_ATTRIB_COLOR_INDEX, EMIT_1F, index );
+
if (RENDERINPUTS_TEST( index_bitset, _TNL_ATTRIB_FOG ))
EMIT_ATTR( _TNL_ATTRIB_FOG, EMIT_1F, fog);
@@ -152,9 +155,6 @@ _swsetup_RenderStart( GLcontext *ctx )
}
}
- if (RENDERINPUTS_TEST( index_bitset, _TNL_ATTRIB_INDEX ))
- EMIT_ATTR( _TNL_ATTRIB_INDEX, EMIT_1F, index );
-
if (RENDERINPUTS_TEST( index_bitset, _TNL_ATTRIB_POINTSIZE ))
EMIT_ATTR( _TNL_ATTRIB_POINTSIZE, EMIT_1F, pointSize );
@@ -247,8 +247,8 @@ _swsetup_Translate( GLcontext *ctx, const void *vertex, SWvertex *dest )
_tnl_get_attr( ctx, vertex, _TNL_ATTRIB_FOG, tmp );
dest->fog = tmp[0];
- _tnl_get_attr( ctx, vertex, _TNL_ATTRIB_INDEX, tmp );
- dest->index = (GLuint) tmp[0];
+ _tnl_get_attr( ctx, vertex, _TNL_ATTRIB_COLOR_INDEX, tmp );
+ dest->index = tmp[0];
_tnl_get_attr( ctx, vertex, _TNL_ATTRIB_POINTSIZE, tmp );
dest->pointSize = tmp[0];