aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian <[email protected]>2007-04-24 16:16:25 -0600
committerBrian <[email protected]>2007-04-24 16:16:25 -0600
commit8a8a5bd104e8cd9362415db77d5f6a3945939589 (patch)
tree5b00efdad5ca9e295ff51e1b39cdfa9d8d884e70
parent3e5eda9ee9ff7c0e393dcc5ecb88198f1990c32f (diff)
s/INTERP_TEX/INTERP_ATTRIBS/
-rw-r--r--src/mesa/swrast/s_triangle.c4
-rw-r--r--src/mesa/swrast/s_tritemp.h19
2 files changed, 12 insertions, 11 deletions
diff --git a/src/mesa/swrast/s_triangle.c b/src/mesa/swrast/s_triangle.c
index 3b7960bf80f..dbb634e3364 100644
--- a/src/mesa/swrast/s_triangle.c
+++ b/src/mesa/swrast/s_triangle.c
@@ -803,7 +803,7 @@ fast_persp_span(GLcontext *ctx, SWspan *span,
#define INTERP_FOG 1
#define INTERP_RGB 1
#define INTERP_ALPHA 1
-#define INTERP_TEX 1
+#define INTERP_ATTRIBS 1
#define SETUP_CODE \
struct persp_info info; \
@@ -874,7 +874,7 @@ fast_persp_span(GLcontext *ctx, SWspan *span,
#define INTERP_RGB 1
#define INTERP_SPEC 1
#define INTERP_ALPHA 1
-#define INTERP_TEX 1
+#define INTERP_ATTRIBS 1
#define RENDER_SPAN( span ) _swrast_write_rgba_span(ctx, &span);
#include "s_tritemp.h"
diff --git a/src/mesa/swrast/s_tritemp.h b/src/mesa/swrast/s_tritemp.h
index 97c79428c06..b8601bd5b4b 100644
--- a/src/mesa/swrast/s_tritemp.h
+++ b/src/mesa/swrast/s_tritemp.h
@@ -38,7 +38,8 @@
* INTERP_INDEX - if defined, interpolate color index values
* INTERP_INT_TEX - if defined, interpolate integer ST texcoords
* (fast, simple 2-D texture mapping)
- * INTERP_TEX - if defined, interpolate texcoords and varying vars
+ * INTERP_ATTRIBS - if defined, interpolate arbitrary attribs (texcoords,
+ * varying vars, etc)
* NOTE: OpenGL STRQ = Mesa STUV (R was taken for red)
*
* When one can directly address pixels in the color buffer the following
@@ -601,7 +602,7 @@ static void NAME(GLcontext *ctx, const SWvertex *v0,
span.intTexStep[1] = SignedFloatToFixed(span.attrStepX[FRAG_ATTRIB_TEX0][1]);
}
#endif
-#ifdef INTERP_TEX
+#ifdef INTERP_ATTRIBS
span.interpMask |= (SPAN_TEXTURE | SPAN_VARYING);
{
/* win[3] is 1/W */
@@ -719,7 +720,7 @@ static void NAME(GLcontext *ctx, const SWvertex *v0,
GLfixed sLeft=0, dsOuter=0, dsInner;
GLfixed tLeft=0, dtOuter=0, dtInner;
#endif
-#ifdef INTERP_TEX
+#ifdef INTERP_ATTRIBS
GLfloat sLeft[FRAG_ATTRIB_MAX];
GLfloat tLeft[FRAG_ATTRIB_MAX];
GLfloat uLeft[FRAG_ATTRIB_MAX];
@@ -986,7 +987,7 @@ static void NAME(GLcontext *ctx, const SWvertex *v0,
dtOuter = SignedFloatToFixed(span.attrStepY[FRAG_ATTRIB_TEX0][1] + dxOuter * span.attrStepX[FRAG_ATTRIB_TEX0][1]);
}
#endif
-#ifdef INTERP_TEX
+#ifdef INTERP_ATTRIBS
ATTRIB_LOOP_BEGIN
const GLfloat invW = vLower->win[3];
const GLfloat s0 = vLower->attrib[attr][0] * invW;
@@ -1057,7 +1058,7 @@ static void NAME(GLcontext *ctx, const SWvertex *v0,
dsInner = dsOuter + span.intTexStep[0];
dtInner = dtOuter + span.intTexStep[1];
#endif
-#ifdef INTERP_TEX
+#ifdef INTERP_ATTRIBS
ATTRIB_LOOP_BEGIN
dsInner[attr] = dsOuter[attr] + span.attrStepX[attr][0];
dtInner[attr] = dtOuter[attr] + span.attrStepX[attr][1];
@@ -1106,7 +1107,7 @@ static void NAME(GLcontext *ctx, const SWvertex *v0,
span.intTex[1] = tLeft;
#endif
-#ifdef INTERP_TEX
+#ifdef INTERP_ATTRIBS
ATTRIB_LOOP_BEGIN
span.attrStart[attr][0] = sLeft[attr];
span.attrStart[attr][1] = tLeft[attr];
@@ -1194,7 +1195,7 @@ static void NAME(GLcontext *ctx, const SWvertex *v0,
sLeft += dsOuter;
tLeft += dtOuter;
#endif
-#ifdef INTERP_TEX
+#ifdef INTERP_ATTRIBS
ATTRIB_LOOP_BEGIN
sLeft[attr] += dsOuter[attr];
tLeft[attr] += dtOuter[attr];
@@ -1239,7 +1240,7 @@ static void NAME(GLcontext *ctx, const SWvertex *v0,
sLeft += dsInner;
tLeft += dtInner;
#endif
-#ifdef INTERP_TEX
+#ifdef INTERP_ATTRIBS
ATTRIB_LOOP_BEGIN
sLeft[attr] += dsInner[attr];
tLeft[attr] += dtInner[attr];
@@ -1276,7 +1277,7 @@ static void NAME(GLcontext *ctx, const SWvertex *v0,
#undef INTERP_SPEC
#undef INTERP_INDEX
#undef INTERP_INT_TEX
-#undef INTERP_TEX
+#undef INTERP_ATTRIBS
#undef TEX_UNIT_LOOP
#undef VARYING_LOOP