For lod query instructions, we really don't care whether or not the sampler is an array type because that doesn't factor into the LOD.
Signed-off-by: Jason Ekstrand <ja...@jlekstrand.net> Cc: "12.0" <mesa-dev@lists.freedesktop.org> --- src/compiler/spirv/spirv_to_nir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/compiler/spirv/spirv_to_nir.c b/src/compiler/spirv/spirv_to_nir.c index b1bb48b..6654f5f 100644 --- a/src/compiler/spirv/spirv_to_nir.c +++ b/src/compiler/spirv/spirv_to_nir.c @@ -1511,7 +1511,7 @@ vtn_handle_texture(struct vtn_builder *b, SpvOp opcode, assert("Invalid sampler type"); } - if (instr->is_array) + if (instr->is_array && instr->op != nir_texop_lod) instr->coord_components++; } else { instr->coord_components = 0; -- 2.5.0.400.gff86faf _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev