From 3d6fe93382699a61911e979db46c1297865c508b Mon Sep 17 00:00:00 2001 From: Connor Abbott Date: Tue, 8 Dec 2020 12:42:05 +0100 Subject: [PATCH] ntt: Handle sized tex destination types I believe this code doesn't handle 16-bit destination types so we only need to handle float32, etc. Reviewed-by: Jason Ekstrand Part-of: --- src/gallium/auxiliary/nir/nir_to_tgsi.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gallium/auxiliary/nir/nir_to_tgsi.c b/src/gallium/auxiliary/nir/nir_to_tgsi.c index fbc96b35160..8a48435f715 100644 --- a/src/gallium/auxiliary/nir/nir_to_tgsi.c +++ b/src/gallium/auxiliary/nir/nir_to_tgsi.c @@ -2041,12 +2041,15 @@ ntt_emit_texture(struct ntt_compile *c, nir_tex_instr *instr) enum tgsi_return_type tex_type; switch (instr->dest_type) { + case nir_type_float32: case nir_type_float: tex_type = TGSI_RETURN_TYPE_FLOAT; break; + case nir_type_int32: case nir_type_int: tex_type = TGSI_RETURN_TYPE_SINT; break; + case nir_type_uint32: case nir_type_uint: tex_type = TGSI_RETURN_TYPE_UINT; break;