Lines Matching defs:tex
93 nir_tex_instr *tex = nir_instr_as_tex(instr);
98 assert(tex->sampler_index == tex->texture_index);
100 for (unsigned i = 0; i < tex->num_srcs; i++) {
101 switch (tex->src[i].src_type) {
103 coord = &tex->src[i].src;
108 src1 = &tex->src[i].src;
126 assert(coord && src1 && tex->coord_components < 4);
129 for (unsigned i = 0; i < tex->coord_components; i++) {
133 for (unsigned i = tex->coord_components; i < 4; i++)
139 nir_tex_instr_remove_src(tex, src1_idx);
140 nir_instr_rewrite_src(&tex->instr, coord, nir_src_for_ssa(&vec->dest.dest.ssa));
141 tex->coord_components = 4;
143 nir_instr_insert_before(&tex->instr, &vec->instr);