summaryrefslogtreecommitdiff
path: root/src/mesa/state_tracker/st_mesa_to_tgsi.c
diff options
context:
space:
mode:
authorJakob Bornecrantz <jakob@tungstengraphics.com>2008-09-17 18:11:35 +0200
committerJakob Bornecrantz <jakob@tungstengraphics.com>2008-09-17 18:13:17 +0200
commitec8398d62f5e5084e9eeb98ed55324ab98214248 (patch)
treeaf1bae45e45f4395533f869815ec7d88c0a60d0c /src/mesa/state_tracker/st_mesa_to_tgsi.c
parentf8a5cb8cb2fde732016888a2554872d702803c01 (diff)
tgsi: Add a ugly fix for CONSTANT problems
Diffstat (limited to 'src/mesa/state_tracker/st_mesa_to_tgsi.c')
-rw-r--r--src/mesa/state_tracker/st_mesa_to_tgsi.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_mesa_to_tgsi.c b/src/mesa/state_tracker/st_mesa_to_tgsi.c
index 49abee15a1..ff0bc04619 100644
--- a/src/mesa/state_tracker/st_mesa_to_tgsi.c
+++ b/src/mesa/state_tracker/st_mesa_to_tgsi.c
@@ -241,6 +241,15 @@ compile_instruction(
immediateMapping,
indirectAccess );
+ /**
+ * This not at all the correct solution.
+ * FIXME: Roll this up in the above map functions
+ */
+ if (fullsrc->SrcRegister.File == TGSI_FILE_IMMEDIATE && fullsrc->SrcRegister.Index == ~0) {
+ fullsrc->SrcRegister.File = TGSI_FILE_CONSTANT;
+ fullsrc->SrcRegister.Index = inst->SrcReg[i].Index;
+ }
+
/* swizzle (ext swizzle also depends on negation) */
{
GLuint swz[4];