summaryrefslogtreecommitdiff
path: root/src/mesa/shader/prog_execute.c
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2009-04-01 18:50:07 -0600
committerBrian Paul <brianp@vmware.com>2009-04-01 18:50:07 -0600
commit1ab225017ed1ea8bd9e266d10ee56ab914bb28c1 (patch)
tree025e09003fea9d1c50d16a0cfbb3bfdf4f41b89e /src/mesa/shader/prog_execute.c
parent9cc79fc2dcdd8e21d9616cc65a931f1f5859fc30 (diff)
mesa: use correct tex unit lod bias for TXB instruction
Diffstat (limited to 'src/mesa/shader/prog_execute.c')
-rw-r--r--src/mesa/shader/prog_execute.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/shader/prog_execute.c b/src/mesa/shader/prog_execute.c
index a60cda674ba..0bc8d5f6a79 100644
--- a/src/mesa/shader/prog_execute.c
+++ b/src/mesa/shader/prog_execute.c
@@ -1540,8 +1540,8 @@ _mesa_execute_program(GLcontext * ctx,
case OPCODE_TXB: /* GL_ARB_fragment_program only */
/* Texel lookup with LOD bias */
{
- const struct gl_texture_unit *texUnit
- = &ctx->Texture.Unit[inst->TexSrcUnit];
+ const GLuint unit = machine->Samplers[inst->TexSrcUnit];
+ const struct gl_texture_unit *texUnit = &ctx->Texture.Unit[unit];
GLfloat texcoord[4], color[4], lodBias;
fetch_vector4(&inst->SrcReg[0], machine, texcoord);