summaryrefslogtreecommitdiffstats
path: root/src/mesa/tnl/t_vb_fog.c
diff options
context:
space:
mode:
authorH. Verbeet <[email protected]>2008-06-16 10:40:32 -0600
committerBrian Paul <[email protected]>2008-06-16 10:40:32 -0600
commite9d1889891ce32ffb3d6425f1e70510ea2c3e24b (patch)
treeddbf903fc2c8574c0e5d552ea12cc581c69f41a3 /src/mesa/tnl/t_vb_fog.c
parentec2d0decbd739df99cac4baba57fe0005bf4894d (diff)
Compute/setup fog coordinates even if vertex program is enabled.
Only when fog's enabled, of course. In the usual case, this is just a pass-through operation.
Diffstat (limited to 'src/mesa/tnl/t_vb_fog.c')
-rw-r--r--src/mesa/tnl/t_vb_fog.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mesa/tnl/t_vb_fog.c b/src/mesa/tnl/t_vb_fog.c
index d8bca3820bc..99e5a09c755 100644
--- a/src/mesa/tnl/t_vb_fog.c
+++ b/src/mesa/tnl/t_vb_fog.c
@@ -148,11 +148,11 @@ run_fog_stage(GLcontext *ctx, struct tnl_pipeline_stage *stage)
struct fog_stage_data *store = FOG_STAGE_DATA(stage);
GLvector4f *input;
- if (!ctx->Fog.Enabled || ctx->VertexProgram._Current)
- return GL_TRUE;
+ if (!ctx->Fog.Enabled)
+ return GL_TRUE;
- if (ctx->Fog.FogCoordinateSource == GL_FRAGMENT_DEPTH_EXT) {
+ if (ctx->Fog.FogCoordinateSource == GL_FRAGMENT_DEPTH_EXT && !ctx->VertexProgram._Current) {
GLuint i;
GLfloat *coord;
/* Fog is computed from vertex or fragment Z values */