Instead of computing it once again using _mesa_tex_target_to_index.
Signed-off-by: Gustaw Smolarczyk <[email protected]>
---
src/mesa/main/ff_fragment_shader.cpp | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/src/mesa/main/ff_fragment_shader.cpp
b/src/mesa/main/ff_fragment_shader.cpp
index 717f39e9d3..2b4d99c879 100644
--- a/src/mesa/main/ff_fragment_shader.cpp
+++ b/src/mesa/main/ff_fragment_shader.cpp
@@ -414,8 +414,7 @@ static GLuint make_state_key( struct gl_context *ctx,
struct state_key *key )
key->unit[i].enabled = 1;
inputs_referenced |= VARYING_BIT_TEX(i);
- key->unit[i].source_index = _mesa_tex_target_to_index(ctx,
- texObj->Target);
+ key->unit[i].source_index = texObj->TargetIndex;
key->unit[i].shadow =
((samp->CompareMode == GL_COMPARE_R_TO_TEXTURE) &&
--
2.12.1
_______________________________________________
mesa-dev mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/mesa-dev