From 9d95d64be0893a18922da75d2625235ae410d3ab Mon Sep 17 00:00:00 2001 From: Ilia Mirkin Date: Tue, 6 May 2014 02:51:45 -0400 Subject: [PATCH] mesa: pass target through to driver when choosing texture format This only matters for TextureView where the texObj's target has not been set yet, in all other instances, texObj->target should be the same as the passed-in target parameter. Signed-off-by: Ilia Mirkin Reviewed-by: Brian Paul --- src/mesa/main/teximage.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index c7f301c..845ba80 100644 --- a/src/mesa/main/teximage.c +++ b/src/mesa/main/teximage.c @@ -3024,7 +3024,7 @@ _mesa_choose_texture_format(struct gl_context *ctx, } /* choose format from scratch */ - f = ctx->Driver.ChooseTextureFormat(ctx, texObj->Target, internalFormat, + f = ctx->Driver.ChooseTextureFormat(ctx, target, internalFormat, format, type); ASSERT(f != MESA_FORMAT_NONE); return f; -- 2.7.4