summaryrefslogtreecommitdiff
path: root/src/mesa
diff options
context:
space:
mode:
authorBrian <brian.paul@tungstengraphics.com>2008-01-16 13:54:32 -0700
committerBrian <brian.paul@tungstengraphics.com>2008-01-16 13:54:32 -0700
commit27cff4402e9582fed8152e88a2c36e488bf76198 (patch)
tree962a8e840cc945fae5243f5c726bbdadc97682d5 /src/mesa
parentd11fd189ff84ec24df0fb988e5c3e1a9260e038c (diff)
copy UsesKill state in _mesa_combine_programs()
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/shader/program.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/mesa/shader/program.c b/src/mesa/shader/program.c
index fc53b5737c..3869e31714 100644
--- a/src/mesa/shader/program.c
+++ b/src/mesa/shader/program.c
@@ -497,6 +497,13 @@ _mesa_combine_programs(GLcontext *ctx,
newProg->NumInstructions = newLength;
if (newProg->Target == GL_FRAGMENT_PROGRAM_ARB) {
+ struct gl_fragment_program *fprogA, *fprogB, *newFprog;
+ fprogA = (struct gl_fragment_program *) progA;
+ fprogB = (struct gl_fragment_program *) progB;
+ newFprog = (struct gl_fragment_program *) newProg;
+
+ newFprog->UsesKill = fprogA->UsesKill || fprogB->UsesKill;
+
/* connect color outputs/inputs */
if ((progA->OutputsWritten & (1 << FRAG_RESULT_COLR)) &&
(progB->InputsRead & (1 << FRAG_ATTRIB_COL0))) {