summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2008-09-17 16:49:26 -0600
committerBrian Paul <[email protected]>2008-09-17 16:49:26 -0600
commit4ee8d1ad679ea8540e91616933a880cdb3836a19 (patch)
treeb44a0bf30bf790412971438a41f2cc1632297e15 /src
parentd7a7b0a10dd355fbeb7a404091a42d4ab558c820 (diff)
gallium: fix fog vs. pointcoord attribute handling in mesa->TGSI conversion
Diffstat (limited to 'src')
-rw-r--r--src/mesa/state_tracker/st_program.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mesa/state_tracker/st_program.c b/src/mesa/state_tracker/st_program.c
index 936a6e32ea1..b2abf0286e7 100644
--- a/src/mesa/state_tracker/st_program.c
+++ b/src/mesa/state_tracker/st_program.c
@@ -409,7 +409,10 @@ st_translate_fragment_program(struct st_context *st,
interpMode[slot] = TGSI_INTERPOLATE_LINEAR;
break;
case FRAG_ATTRIB_FOGC:
- stfp->input_semantic_name[slot] = TGSI_SEMANTIC_FOG;
+ if (stfp->Base.UsesPointCoord)
+ stfp->input_semantic_name[slot] = TGSI_SEMANTIC_GENERIC;
+ else
+ stfp->input_semantic_name[slot] = TGSI_SEMANTIC_FOG;
stfp->input_semantic_index[slot] = 0;
interpMode[slot] = TGSI_INTERPOLATE_PERSPECTIVE;
break;