From 1fe385fdc96688a5249d52184f457910a0c25488 Mon Sep 17 00:00:00 2001 From: Brian Date: Fri, 14 Dec 2007 11:42:28 -0700 Subject: [PATCH] set SamplerUnit[] entry in load_texture() just to be safe (cherry picked from commit fce4612f8a29ee1798c9326a431a139d856c7a04) --- src/mesa/main/texenvprogram.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/mesa/main/texenvprogram.c b/src/mesa/main/texenvprogram.c index bcf91022244..dcd7f905679 100644 --- a/src/mesa/main/texenvprogram.c +++ b/src/mesa/main/texenvprogram.c @@ -957,6 +957,10 @@ static void load_texture( struct texenv_fragment_program *p, GLuint unit ) p->program->Base.ShadowSamplers |= 1 << unit; p->program->Base.SamplersUsed |= (1 << unit); + /* This identity mapping should already be in place + * (see _mesa_init_program_struct()) but let's be safe. + */ + p->program->Base.SamplerUnits[unit] = unit; } else p->src_texture[unit] = get_zero(p); -- 2.30.2