-#ifdef INTERP_SPEC
- span.interpMask |= SPAN_SPEC;
- if (ctx->Light.ShadeModel == GL_SMOOTH) {
- GLfloat eMaj_dsr = (GLfloat) ((ColorTemp) vMax->specular[RCOMP] - vMin->specular[RCOMP]);
- GLfloat eBot_dsr = (GLfloat) ((ColorTemp) vMid->specular[RCOMP] - vMin->specular[RCOMP]);
- GLfloat eMaj_dsg = (GLfloat) ((ColorTemp) vMax->specular[GCOMP] - vMin->specular[GCOMP]);
- GLfloat eBot_dsg = (GLfloat) ((ColorTemp) vMid->specular[GCOMP] - vMin->specular[GCOMP]);
- GLfloat eMaj_dsb = (GLfloat) ((ColorTemp) vMax->specular[BCOMP] - vMin->specular[BCOMP]);
- GLfloat eBot_dsb = (GLfloat) ((ColorTemp) vMid->specular[BCOMP] - vMin->specular[BCOMP]);
- span.dsrdx = oneOverArea * (eMaj_dsr * eBot.dy - eMaj.dy * eBot_dsr);
- span.dsrdy = oneOverArea * (eMaj.dx * eBot_dsr - eMaj_dsr * eBot.dx);
- span.dsgdx = oneOverArea * (eMaj_dsg * eBot.dy - eMaj.dy * eBot_dsg);
- span.dsgdy = oneOverArea * (eMaj.dx * eBot_dsg - eMaj_dsg * eBot.dx);
- span.dsbdx = oneOverArea * (eMaj_dsb * eBot.dy - eMaj.dy * eBot_dsb);
- span.dsbdy = oneOverArea * (eMaj.dx * eBot_dsb - eMaj_dsb * eBot.dx);
-# if CHAN_TYPE == GL_FLOAT
- span.specRedStep = span.dsrdx;
- span.specGreenStep = span.dsgdx;
- span.specBlueStep = span.dsbdx;
-# else
- span.specRedStep = SignedFloatToFixed(span.dsrdx);
- span.specGreenStep = SignedFloatToFixed(span.dsgdx);
- span.specBlueStep = SignedFloatToFixed(span.dsbdx);
-# endif
- }
- else {
- span.dsrdx = span.dsrdy = 0.0F;
- span.dsgdx = span.dsgdy = 0.0F;
- span.dsbdx = span.dsbdy = 0.0F;
-# if CHAN_TYPE == GL_FLOAT
- span.specRedStep = 0.0F;
- span.specGreenStep = 0.0F;
- span.specBlueStep = 0.0F;
-# else
- span.specRedStep = 0;
- span.specGreenStep = 0;
- span.specBlueStep = 0;
-# endif
- }
-#endif /* INTERP_SPEC */
-#ifdef INTERP_INDEX
- span.interpMask |= SPAN_INDEX;
- if (ctx->Light.ShadeModel == GL_SMOOTH) {
- GLfloat eMaj_di = (GLfloat) ((GLint) vMax->index - (GLint) vMin->index);
- GLfloat eBot_di = (GLfloat) ((GLint) vMid->index - (GLint) vMin->index);
- didx = oneOverArea * (eMaj_di * eBot.dy - eMaj.dy * eBot_di);
- didy = oneOverArea * (eMaj.dx * eBot_di - eMaj_di * eBot.dx);
- span.indexStep = SignedFloatToFixed(didx);
- }
- else {
- span.interpMask |= SPAN_FLAT;
- didx = didy = 0.0F;
- span.indexStep = 0;
- }
-#endif