st/mesa: add missing case for PIPE_FORMAT_B8G8R8A8_UNORM
[mesa.git] / src / mesa / swrast / s_fog.c
index ed47964a66aeae42ada37b89c20fc4f78fa85bc6..77ed0cfef9611a2f27137eaf3733156686ffc950 100644 (file)
  */
 
 
-#include "glheader.h"
-#include "colormac.h"
-#include "context.h"
-#include "macros.h"
+#include "main/glheader.h"
+#include "main/colormac.h"
+#include "main/context.h"
+#include "main/macros.h"
 
 #include "s_context.h"
 #include "s_fog.h"
@@ -164,11 +164,10 @@ else {                                                                            \
 void
 _swrast_fog_rgba_span( const GLcontext *ctx, SWspan *span )
 {
-   const SWcontext *swrast = SWRAST_CONTEXT(ctx);
+   const SWcontext *swrast = CONST_SWRAST_CONTEXT(ctx);
    GLfloat rFog, gFog, bFog;
 
    ASSERT(swrast->_FogEnabled);
-   ASSERT(swrast->_ActiveAttribMask & FRAG_BIT_FOGC);
    ASSERT(span->arrayMask & SPAN_RGBA);
 
    /* compute (scaled) fog color */
@@ -284,7 +283,7 @@ _swrast_fog_rgba_span( const GLcontext *ctx, SWspan *span )
 void
 _swrast_fog_ci_span( const GLcontext *ctx, SWspan *span )
 {
-   const SWcontext *swrast = SWRAST_CONTEXT(ctx);
+   const SWcontext *swrast = CONST_SWRAST_CONTEXT(ctx);
    const GLuint fogIndex = (GLuint) ctx->Fog.Index;
    GLuint *index = span->array->index;