aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/mesa/drivers/dri/r200/r200_tcl.c2
-rw-r--r--src/mesa/drivers/dri/r200/r200_vtxfmt.c5
-rw-r--r--src/mesa/drivers/dri/radeon/radeon_maos_arrays.c4
3 files changed, 7 insertions, 4 deletions
diff --git a/src/mesa/drivers/dri/r200/r200_tcl.c b/src/mesa/drivers/dri/r200/r200_tcl.c
index 55e7b490794..f6461a164e6 100644
--- a/src/mesa/drivers/dri/r200/r200_tcl.c
+++ b/src/mesa/drivers/dri/r200/r200_tcl.c
@@ -400,7 +400,7 @@ static GLboolean r200_run_tcl_render( GLcontext *ctx,
}
}
- if ( ctx->Fog.FogCoordinateSource == GL_FOG_COORD ) {
+ if ( (ctx->Fog.FogCoordinateSource == GL_FOG_COORD) && ctx->Fog.Enabled ) {
inputs |= VERT_BIT_FOG;
}
diff --git a/src/mesa/drivers/dri/r200/r200_vtxfmt.c b/src/mesa/drivers/dri/r200/r200_vtxfmt.c
index c5d1f131d06..d9af6bf5f85 100644
--- a/src/mesa/drivers/dri/r200/r200_vtxfmt.c
+++ b/src/mesa/drivers/dri/r200/r200_vtxfmt.c
@@ -662,9 +662,10 @@ static GLboolean check_vtx_fmt( GLcontext *ctx )
GLuint i;
GLuint count[R200_MAX_TEXTURE_UNITS];
- if (rmesa->TclFallback || rmesa->vb.fell_back || ctx->CompileFlag)
+ if (rmesa->TclFallback || rmesa->vb.fell_back || ctx->CompileFlag ||
+ (ctx->Fog.Enabled && (ctx->Fog.FogCoordinateSource == GL_FOG_COORD)))
return GL_FALSE;
-
+
if (ctx->Driver.NeedFlush & FLUSH_UPDATE_CURRENT)
ctx->Driver.FlushVertices( ctx, FLUSH_UPDATE_CURRENT );
diff --git a/src/mesa/drivers/dri/radeon/radeon_maos_arrays.c b/src/mesa/drivers/dri/radeon/radeon_maos_arrays.c
index 49d64148ca1..49118b5e37b 100644
--- a/src/mesa/drivers/dri/radeon/radeon_maos_arrays.c
+++ b/src/mesa/drivers/dri/radeon/radeon_maos_arrays.c
@@ -566,7 +566,9 @@ void radeonEmitArrays( GLcontext *ctx, GLuint inputs )
component[nr++] = &rmesa->tcl.spec;
}
-
+/* FIXME: not sure if this is correct. May need to stitch this together with
+ secondary color. It seems odd that for primary color color and alpha values
+ are emitted together but for secondary color not. */
if (inputs & VERT_BIT_FOG) {
if (!rmesa->tcl.fog.buf)
emit_vecfog( ctx,