Lines Matching defs:txl
835 /* txb(s, coord, bias) = txl(s, coord, lod(s, coord).y + bias) */
840 nir_tex_instr *txl = nir_tex_instr_create(b->shader, tex->num_srcs);
842 txl->op = nir_texop_txl;
843 txl->sampler_dim = tex->sampler_dim;
844 txl->dest_type = tex->dest_type;
845 txl->coord_components = tex->coord_components;
846 txl->texture_index = tex->texture_index;
847 txl->sampler_index = tex->sampler_index;
848 txl->is_array = tex->is_array;
849 txl->is_shadow = tex->is_shadow;
850 txl->is_new_style_shadow = tex->is_new_style_shadow;
855 nir_src_copy(&txl->src[i].src, &tex->src[i].src);
856 txl->src[i].src_type = tex->src[i].src_type;
859 nir_ssa_def *lod = nir_get_texture_lod(b, txl);
864 txl->src[tex->num_srcs - 1].src = nir_src_for_ssa(lod);
865 txl->src[tex->num_srcs - 1].src_type = nir_tex_src_lod;
867 nir_ssa_dest_init(&txl->instr, &txl->dest, nir_dest_num_components(tex->dest),
869 nir_builder_instr_insert(b, &txl->instr);
870 nir_ssa_def_rewrite_uses(&tex->dest.ssa, &txl->dest.ssa);
872 return txl;