summaryrefslogtreecommitdiff
path: root/src/mesa/shader/program.c
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2005-11-08 14:42:52 +0000
committerBrian Paul <brian.paul@tungstengraphics.com>2005-11-08 14:42:52 +0000
commit02df9e1ed49a8b86a4e285cc55efbeda4908a835 (patch)
tree04ae8a34cafc717b4a3257450f80ad80a5624557 /src/mesa/shader/program.c
parent832026f90643f9162daceeb1be7c9b2f2e7b68c0 (diff)
minor work in _mesa_print_program()
Diffstat (limited to 'src/mesa/shader/program.c')
-rw-r--r--src/mesa/shader/program.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/mesa/shader/program.c b/src/mesa/shader/program.c
index d762205c29..a77c447e28 100644
--- a/src/mesa/shader/program.c
+++ b/src/mesa/shader/program.c
@@ -1179,7 +1179,16 @@ _mesa_print_program(GLuint count, const struct prog_instruction *inst)
switch (inst[i].Opcode) {
case OPCODE_PRINT:
- _mesa_printf("PRINT %s\n", inst->Data);
+ _mesa_printf("PRINT '%s'", inst[i].Data);
+ if (inst->SrcReg[0].File != PROGRAM_UNDEFINED) {
+ _mesa_printf(", ");
+ _mesa_printf("%s[%d]%s",
+ program_file_string(inst[i].SrcReg[0].File),
+ inst[i].SrcReg[0].Index,
+ swizzle_string(inst[i].SrcReg[0].Swizzle,
+ inst[i].SrcReg[0].NegateBase));
+ }
+ _mesa_printf(";\n");
break;
/* XXX check for a bunch of other special-case instructions */
default: