Mesa (mesa_7_5_branch): mesa: when emitting vertex program fog, set yzw=0, 0 ,1
Brian Paul
brianp at kemper.freedesktop.org
Tue Aug 18 23:42:39 UTC 2009
Module: Mesa
Branch: mesa_7_5_branch
Commit: ee0984e299f7a48fbd3a0172ec9c471e0e8cbb92
URL: http://cgit.freedesktop.org/mesa/mesa/commit/?id=ee0984e299f7a48fbd3a0172ec9c471e0e8cbb92
Author: Brian Paul <brianp at vmware.com>
Date: Tue Aug 18 17:39:55 2009 -0600
mesa: when emitting vertex program fog, set yzw=0,0,1
Fixes piglit fp-fog failure with gallium.
---
src/mesa/main/ffvertex_prog.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/src/mesa/main/ffvertex_prog.c b/src/mesa/main/ffvertex_prog.c
index 80dde4b..8e21a27 100644
--- a/src/mesa/main/ffvertex_prog.c
+++ b/src/mesa/main/ffvertex_prog.c
@@ -1306,7 +1306,9 @@ static void build_fog( struct tnl_program *p )
input = swizzle1(register_input(p, VERT_ATTRIB_FOG), X);
}
+ /* result.fog = {abs(f),0,0,1}; */
emit_op1(p, OPCODE_ABS, fog, WRITEMASK_X, input);
+ emit_op1(p, OPCODE_MOV, fog, WRITEMASK_YZW, get_identity_param(p));
}
More information about the mesa-commit
mailing list