From a9d3b0050251821d3c2571fa310fc8030a7e9e72 Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Wed, 26 May 2021 10:11:01 -0400 Subject: [PATCH] zink: remove weird lod hack for texturing this breaks texturing in non-fragment stages and is unnecessary due to using nir_lower_tex Cc: mesa-stable@lists.freedesktop.org Reviewed-by: Erik Faye-Lund Part-of: --- src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c b/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c index d6e020a9b81..62ef3ccd1eb 100644 --- a/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c +++ b/src/gallium/drivers/zink/nir_to_spirv/nir_to_spirv.c @@ -2954,11 +2954,6 @@ emit_tex(struct ntv_context *ctx, nir_tex_instr *tex) } } - if (lod == 0 && ctx->stage != MESA_SHADER_FRAGMENT) { - lod = emit_float_const(ctx, 32, 0.0f); - assert(lod != 0); - } - unsigned texture_index = tex->texture_index; if (!tex_offset) { /* convert constant index back to base + offset */