From dcf4c17fb1624af47181c63af4c3ad29f919c17a Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Mon, 31 Oct 2005 19:46:55 +0000 Subject: check swrast->_FogEnabled instead of ctx->Fog.Enabled --- src/mesa/swrast/s_drawpix.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) (limited to 'src/mesa/swrast/s_drawpix.c') diff --git a/src/mesa/swrast/s_drawpix.c b/src/mesa/swrast/s_drawpix.c index ce398b2..bdccd1c 100644 --- a/src/mesa/swrast/s_drawpix.c +++ b/src/mesa/swrast/s_drawpix.c @@ -67,7 +67,7 @@ fast_draw_pixels(GLcontext *ctx, GLint x, GLint y, if (ctx->Depth.Test) _swrast_span_default_z(ctx, &span); - if (ctx->Fog.Enabled) + if (swrast->_FogEnabled) _swrast_span_default_fog(ctx, &span); if (ctx->Texture._EnabledCoordUnits) _swrast_span_default_texcoords(ctx, &span); @@ -456,6 +456,7 @@ draw_index_pixels( GLcontext *ctx, GLint x, GLint y, const struct gl_pixelstore_attrib *unpack, const GLvoid *pixels ) { + SWcontext *swrast = SWRAST_CONTEXT(ctx); const GLint imgX = x, imgY = y; const GLboolean zoom = ctx->Pixel.ZoomX!=1.0 || ctx->Pixel.ZoomY!=1.0; GLint row, skipPixels; @@ -465,7 +466,7 @@ draw_index_pixels( GLcontext *ctx, GLint x, GLint y, if (ctx->Depth.Test) _swrast_span_default_z(ctx, &span); - if (ctx->Fog.Enabled) + if (swrast->_FogEnabled) _swrast_span_default_fog(ctx, &span); /* @@ -561,6 +562,7 @@ draw_depth_pixels( GLcontext *ctx, GLint x, GLint y, const struct gl_pixelstore_attrib *unpack, const GLvoid *pixels ) { + SWcontext *swrast = SWRAST_CONTEXT(ctx); const GLboolean scaleOrBias = ctx->Pixel.DepthScale != 1.0 || ctx->Pixel.DepthBias != 0.0; const GLboolean zoom = ctx->Pixel.ZoomX != 1.0 || ctx->Pixel.ZoomY != 1.0; @@ -570,7 +572,7 @@ draw_depth_pixels( GLcontext *ctx, GLint x, GLint y, _swrast_span_default_color(ctx, &span); - if (ctx->Fog.Enabled) + if (swrast->_FogEnabled) _swrast_span_default_fog(ctx, &span); if (ctx->Texture._EnabledCoordUnits) _swrast_span_default_texcoords(ctx, &span); @@ -675,6 +677,7 @@ draw_rgba_pixels( GLcontext *ctx, GLint x, GLint y, const struct gl_pixelstore_attrib *unpack, const GLvoid *pixels ) { + SWcontext *swrast = SWRAST_CONTEXT(ctx); const GLint imgX = x, imgY = y; struct gl_renderbuffer *rb = NULL; /* only used for quickDraw path */ const GLboolean zoom = ctx->Pixel.ZoomX!=1.0 || ctx->Pixel.ZoomY!=1.0; @@ -691,7 +694,7 @@ draw_rgba_pixels( GLcontext *ctx, GLint x, GLint y, if (ctx->Depth.Test) _swrast_span_default_z(ctx, &span); - if (ctx->Fog.Enabled) + if (swrast->_FogEnabled) _swrast_span_default_fog(ctx, &span); if (ctx->Texture._EnabledCoordUnits) _swrast_span_default_texcoords(ctx, &span); -- cgit v1.1