summaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/i965/brw_vs_tnl.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_vs_tnl.c b/src/mesa/drivers/dri/i965/brw_vs_tnl.c
index b8231fc1d2f..d58fd4c0da2 100644
--- a/src/mesa/drivers/dri/i965/brw_vs_tnl.c
+++ b/src/mesa/drivers/dri/i965/brw_vs_tnl.c
@@ -1172,6 +1172,11 @@ static void build_fog( struct tnl_program *p )
}
else {
input = swizzle1(register_input(p, VERT_ATTRIB_FOG), X);
+ if (p->state->fog_option &&
+ p->state->tnl_do_vertex_fog)
+ input = swizzle1(register_input(p, VERT_ATTRIB_FOG), X);
+ else
+ input = register_input(p, VERT_ATTRIB_FOG);
}
if (p->state->fog_option &&