From: Rob Clark <robcl...@freedesktop.org> Signed-off-by: Rob Clark <robcl...@freedesktop.org> --- src/gallium/auxiliary/nir/tgsi_to_nir.c | 14 ++++++++++++++ 1 file changed, 14 insertions(+)
diff --git a/src/gallium/auxiliary/nir/tgsi_to_nir.c b/src/gallium/auxiliary/nir/tgsi_to_nir.c index 515171c..d370b57 100644 --- a/src/gallium/auxiliary/nir/tgsi_to_nir.c +++ b/src/gallium/auxiliary/nir/tgsi_to_nir.c @@ -1082,6 +1082,20 @@ ttn_tex(struct ttn_compile *c, nir_alu_dest dest, nir_ssa_def **src) setup_texture_info(instr, tgsi_inst->Texture.Texture); + switch (tgsi_inst->Texture.TextureType) { + case TGSI_TEXTURE_TYPE_FLOAT: + instr->dest_type = nir_type_float; + break; + case TGSI_TEXTURE_TYPE_INT: + instr->dest_type = nir_type_int; + break; + case TGSI_TEXTURE_TYPE_UNSIGNED: + instr->dest_type = nir_type_unsigned; + break; + default: + unreachable("not reached"); + } + switch (instr->sampler_dim) { case GLSL_SAMPLER_DIM_1D: case GLSL_SAMPLER_DIM_BUF: -- 2.4.2 _______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev