diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/swrast/s_context.c | 12 | ||||
-rw-r--r-- | src/mesa/swrast/s_span.c | 20 | ||||
-rw-r--r-- | src/mesa/swrast/s_triangle.c | 4 |
3 files changed, 18 insertions, 18 deletions
diff --git a/src/mesa/swrast/s_context.c b/src/mesa/swrast/s_context.c index a265d9e6cef..030313aea60 100644 --- a/src/mesa/swrast/s_context.c +++ b/src/mesa/swrast/s_context.c @@ -98,7 +98,7 @@ _swrast_update_rasterflags( GLcontext *ctx ) rasterMask |= MULTI_DRAW_BIT; /* all color index bits disabled */ } - if (ctx->FragmentProgram._Active) { + if (ctx->FragmentProgram._Enabled) { rasterMask |= FRAGPROG_BIT; } @@ -206,7 +206,7 @@ _swrast_update_fog_state( GLcontext *ctx ) /* determine if fog is needed, and if so, which fog mode */ swrast->_FogEnabled = GL_FALSE; - if (ctx->FragmentProgram._Active) { + if (ctx->FragmentProgram._Enabled) { if (ctx->FragmentProgram._Current->Base.Target==GL_FRAGMENT_PROGRAM_ARB) { const struct gl_fragment_program *fp = ctx->FragmentProgram._Current; @@ -230,7 +230,7 @@ _swrast_update_fog_state( GLcontext *ctx ) static void _swrast_update_fragment_program( GLcontext *ctx ) { - if (ctx->FragmentProgram._Active) { + if (ctx->FragmentProgram._Enabled) { const struct gl_fragment_program *fp = ctx->FragmentProgram._Current; _mesa_load_state_parameters(ctx, fp->Base.Parameters); } @@ -299,7 +299,7 @@ _swrast_validate_triangle( GLcontext *ctx, if (ctx->Texture._EnabledUnits == 0 && NEED_SECONDARY_COLOR(ctx) - && !ctx->FragmentProgram._Active) { + && !ctx->FragmentProgram._Enabled) { /* separate specular color, but no texture */ swrast->SpecTriangle = swrast->Triangle; swrast->Triangle = _swrast_add_spec_terms_triangle; @@ -322,7 +322,7 @@ _swrast_validate_line( GLcontext *ctx, const SWvertex *v0, const SWvertex *v1 ) if (ctx->Texture._EnabledUnits == 0 && NEED_SECONDARY_COLOR(ctx) - && !ctx->FragmentProgram._Active) { + && !ctx->FragmentProgram._Enabled) { swrast->SpecLine = swrast->Line; swrast->Line = _swrast_add_spec_terms_line; } @@ -345,7 +345,7 @@ _swrast_validate_point( GLcontext *ctx, const SWvertex *v0 ) if (ctx->Texture._EnabledUnits == 0 && NEED_SECONDARY_COLOR(ctx) - && !ctx->FragmentProgram._Active) { + && !ctx->FragmentProgram._Enabled) { swrast->SpecPoint = swrast->Point; swrast->Point = _swrast_add_spec_terms_point; } diff --git a/src/mesa/swrast/s_span.c b/src/mesa/swrast/s_span.c index d1431054162..cc7d4113fc3 100644 --- a/src/mesa/swrast/s_span.c +++ b/src/mesa/swrast/s_span.c @@ -129,7 +129,7 @@ _swrast_span_default_texcoords( GLcontext *ctx, struct sw_span *span ) GLuint i; for (i = 0; i < ctx->Const.MaxTextureCoordUnits; i++) { const GLfloat *tc = ctx->Current.RasterTexCoords[i]; - if (ctx->FragmentProgram._Active || ctx->ATIFragmentShader._Enabled) { + if (ctx->FragmentProgram._Enabled || ctx->ATIFragmentShader._Enabled) { COPY_4V(span->tex[i], tc); } else if (tc[3] > 0.0F) { @@ -410,7 +410,7 @@ interpolate_texcoords(GLcontext *ctx, struct sw_span *span) if (obj) { const struct gl_texture_image *img = obj->Image[0][obj->BaseLevel]; needLambda = (obj->MinFilter != obj->MagFilter) - || ctx->FragmentProgram._Active; + || ctx->FragmentProgram._Enabled; texW = img->WidthScale; texH = img->HeightScale; } @@ -435,7 +435,7 @@ interpolate_texcoords(GLcontext *ctx, struct sw_span *span) GLfloat r = span->tex[u][2]; GLfloat q = span->tex[u][3]; GLuint i; - if (ctx->FragmentProgram._Active || ctx->ATIFragmentShader._Enabled || + if (ctx->FragmentProgram._Enabled || ctx->ATIFragmentShader._Enabled || ctx->ShaderObjects._FragmentShaderPresent) { /* do perspective correction but don't divide s, t, r by q */ const GLfloat dwdx = span->dwdx; @@ -487,7 +487,7 @@ interpolate_texcoords(GLcontext *ctx, struct sw_span *span) GLfloat r = span->tex[u][2]; GLfloat q = span->tex[u][3]; GLuint i; - if (ctx->FragmentProgram._Active || ctx->ATIFragmentShader._Enabled || + if (ctx->FragmentProgram._Enabled || ctx->ATIFragmentShader._Enabled || ctx->ShaderObjects._FragmentShaderPresent) { /* do perspective correction but don't divide s, t, r by q */ const GLfloat dwdx = span->dwdx; @@ -546,7 +546,7 @@ interpolate_texcoords(GLcontext *ctx, struct sw_span *span) if (obj) { const struct gl_texture_image *img = obj->Image[0][obj->BaseLevel]; needLambda = (obj->MinFilter != obj->MagFilter) - || ctx->FragmentProgram._Active; + || ctx->FragmentProgram._Enabled; texW = (GLfloat) img->WidthScale; texH = (GLfloat) img->HeightScale; } @@ -571,7 +571,7 @@ interpolate_texcoords(GLcontext *ctx, struct sw_span *span) GLfloat r = span->tex[0][2]; GLfloat q = span->tex[0][3]; GLuint i; - if (ctx->FragmentProgram._Active || ctx->ATIFragmentShader._Enabled || + if (ctx->FragmentProgram._Enabled || ctx->ATIFragmentShader._Enabled || ctx->ShaderObjects._FragmentShaderPresent) { /* do perspective correction but don't divide s, t, r by q */ const GLfloat dwdx = span->dwdx; @@ -623,7 +623,7 @@ interpolate_texcoords(GLcontext *ctx, struct sw_span *span) GLfloat r = span->tex[0][2]; GLfloat q = span->tex[0][3]; GLuint i; - if (ctx->FragmentProgram._Active || ctx->ATIFragmentShader._Enabled || + if (ctx->FragmentProgram._Enabled || ctx->ATIFragmentShader._Enabled || ctx->ShaderObjects._FragmentShaderPresent) { /* do perspective correction but don't divide s, t, r by q */ const GLfloat dwdx = span->dwdx; @@ -1120,7 +1120,7 @@ _swrast_write_rgba_span( GLcontext *ctx, struct sw_span *span) const GLbitfield origInterpMask = span->interpMask; const GLbitfield origArrayMask = span->arrayMask; const GLboolean deferredTexture = !(ctx->Color.AlphaEnabled || - ctx->FragmentProgram._Active || + ctx->FragmentProgram._Enabled || ctx->ShaderObjects._FragmentShaderPresent); ASSERT(span->primitive == GL_POINT || span->primitive == GL_LINE || @@ -1205,7 +1205,7 @@ _swrast_write_rgba_span( GLcontext *ctx, struct sw_span *span) } else #endif - if (ctx->FragmentProgram._Active) { + if (ctx->FragmentProgram._Enabled) { /* frag prog may need Z values */ if (span->interpMask & SPAN_Z) _swrast_span_interpolate_z(ctx, span); @@ -1292,7 +1292,7 @@ _swrast_write_rgba_span( GLcontext *ctx, struct sw_span *span) } else #endif - if (ctx->FragmentProgram._Active) + if (ctx->FragmentProgram._Enabled) _swrast_exec_fragment_program( ctx, span ); else if (ctx->ATIFragmentShader._Enabled) _swrast_exec_fragment_shader( ctx, span ); diff --git a/src/mesa/swrast/s_triangle.c b/src/mesa/swrast/s_triangle.c index 440345fb126..5a1fc8aec17 100644 --- a/src/mesa/swrast/s_triangle.c +++ b/src/mesa/swrast/s_triangle.c @@ -1073,7 +1073,7 @@ _swrast_choose_triangle( GLcontext *ctx ) } } - if (ctx->Texture._EnabledCoordUnits || ctx->FragmentProgram._Active || + if (ctx->Texture._EnabledCoordUnits || ctx->FragmentProgram._Enabled || ctx->ATIFragmentShader._Enabled || ctx->ShaderObjects._FragmentShaderPresent) { /* Ugh, we do a _lot_ of tests to pick the best textured tri func */ const struct gl_texture_object *texObj2D; @@ -1089,7 +1089,7 @@ _swrast_choose_triangle( GLcontext *ctx ) /* First see if we can use an optimized 2-D texture function */ if (ctx->Texture._EnabledCoordUnits == 0x1 - && !ctx->FragmentProgram._Active + && !ctx->FragmentProgram._Enabled && !ctx->ATIFragmentShader._Enabled && !ctx->ShaderObjects._FragmentShaderPresent && ctx->Texture.Unit[0]._ReallyEnabled == TEXTURE_2D_BIT |