summaryrefslogtreecommitdiff
path: root/src/mesa/shader/arbprogparse.c
diff options
context:
space:
mode:
authorBrian Paul <brian.paul@tungstengraphics.com>2008-05-14 16:44:48 -0600
committerBrian Paul <brian.paul@tungstengraphics.com>2008-05-16 15:16:06 -0600
commit1af2b14514146d5f0d48a45165a579e88cc7a867 (patch)
tree09cf51607c0cc208e504b8973295b4b25d88ad02 /src/mesa/shader/arbprogparse.c
parent885cc592dfcc3b46e1896d243f60c38cf18fa54b (diff)
init SamplersUsed bits in _mesa_parse_arb_fragment_program
Diffstat (limited to 'src/mesa/shader/arbprogparse.c')
-rw-r--r--src/mesa/shader/arbprogparse.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mesa/shader/arbprogparse.c b/src/mesa/shader/arbprogparse.c
index 74004e9b13..60aaabe679 100644
--- a/src/mesa/shader/arbprogparse.c
+++ b/src/mesa/shader/arbprogparse.c
@@ -3851,8 +3851,11 @@ _mesa_parse_arb_fragment_program(GLcontext* ctx, GLenum target,
program->Base.NumNativeTexIndirections = ap.Base.NumTexIndirections;
program->Base.InputsRead = ap.Base.InputsRead;
program->Base.OutputsWritten = ap.Base.OutputsWritten;
- for (i = 0; i < MAX_TEXTURE_IMAGE_UNITS; i++)
+ for (i = 0; i < MAX_TEXTURE_IMAGE_UNITS; i++) {
program->Base.TexturesUsed[i] = ap.TexturesUsed[i];
+ if (ap.TexturesUsed[i])
+ program->Base.SamplersUsed |= (1 << i);
+ }
program->Base.ShadowSamplers = ap.ShadowSamplers;
program->FogOption = ap.FogOption;
program->UsesKill = ap.UsesKill;