aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/swrast/s_fragprog.c
diff options
context:
space:
mode:
authorPaul Berry <[email protected]>2013-02-23 09:00:58 -0800
committerPaul Berry <[email protected]>2013-03-15 09:26:17 -0700
commiteed6baf7621fa94e7888f8079b155fc67a08540c (patch)
tree216270e7f3222fcb11b8b3fa1def330908f05a21 /src/mesa/swrast/s_fragprog.c
parentf117abe66414e25be4f7bc61ca0df9e83ddaf543 (diff)
Replace gl_frag_attrib enum with gl_varying_slot.
This patch makes the following search-and-replace changes: gl_frag_attrib -> gl_varying_slot FRAG_ATTRIB_* -> VARYING_SLOT_* FRAG_BIT_* -> VARYING_BIT_* Reviewed-by: Kenneth Graunke <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Tested-by: Brian Paul <[email protected]>
Diffstat (limited to 'src/mesa/swrast/s_fragprog.c')
-rw-r--r--src/mesa/swrast/s_fragprog.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mesa/swrast/s_fragprog.c b/src/mesa/swrast/s_fragprog.c
index 9b60893db3f..1ce2ee45276 100644
--- a/src/mesa/swrast/s_fragprog.c
+++ b/src/mesa/swrast/s_fragprog.c
@@ -162,7 +162,7 @@ init_machine(struct gl_context *ctx, struct gl_program_machine *machine,
const struct gl_fragment_program *program,
const SWspan *span, GLuint col)
{
- GLfloat *wpos = span->array->attribs[FRAG_ATTRIB_WPOS][col];
+ GLfloat *wpos = span->array->attribs[VARYING_SLOT_POS][col];
/* ARB_fragment_coord_conventions */
if (program->OriginUpperLeft)
@@ -177,14 +177,14 @@ init_machine(struct gl_context *ctx, struct gl_program_machine *machine,
machine->DerivX = (GLfloat (*)[4]) span->attrStepX;
machine->DerivY = (GLfloat (*)[4]) span->attrStepY;
- machine->NumDeriv = FRAG_ATTRIB_MAX;
+ machine->NumDeriv = VARYING_SLOT_MAX;
machine->Samplers = program->Base.SamplerUnits;
/* if running a GLSL program (not ARB_fragment_program) */
if (ctx->Shader.CurrentFragmentProgram) {
/* Store front/back facing value */
- machine->Attribs[FRAG_ATTRIB_FACE][col][0] = 1.0F - span->facing;
+ machine->Attribs[VARYING_SLOT_FACE][col][0] = 1.0F - span->facing;
}
machine->CurElement = col;
@@ -223,7 +223,7 @@ run_program(struct gl_context *ctx, SWspan *span, GLuint start, GLuint end)
/* Store result color */
if (outputsWritten & BITFIELD64_BIT(FRAG_RESULT_COLOR)) {
- COPY_4V(span->array->attribs[FRAG_ATTRIB_COL0][i],
+ COPY_4V(span->array->attribs[VARYING_SLOT_COL0][i],
machine->Outputs[FRAG_RESULT_COLOR]);
}
else {
@@ -234,7 +234,7 @@ run_program(struct gl_context *ctx, SWspan *span, GLuint start, GLuint end)
GLuint buf;
for (buf = 0; buf < ctx->DrawBuffer->_NumColorDrawBuffers; buf++) {
if (outputsWritten & BITFIELD64_BIT(FRAG_RESULT_DATA0 + buf)) {
- COPY_4V(span->array->attribs[FRAG_ATTRIB_COL0 + buf][i],
+ COPY_4V(span->array->attribs[VARYING_SLOT_COL0 + buf][i],
machine->Outputs[FRAG_RESULT_DATA0 + buf]);
}
}
@@ -272,7 +272,7 @@ _swrast_exec_fragment_program( struct gl_context *ctx, SWspan *span )
const struct gl_fragment_program *program = ctx->FragmentProgram._Current;
/* incoming colors should be floats */
- if (program->Base.InputsRead & FRAG_BIT_COL0) {
+ if (program->Base.InputsRead & VARYING_BIT_COL0) {
ASSERT(span->array->ChanType == GL_FLOAT);
}