Home
last modified time | relevance | path

Searched refs:Swizzle (Results 1 – 25 of 182) sorted by relevance

12345678

/external/skia/tests/sksl/dslfp/
DGrDSLFPTest_Builtins.dsl.cpp40 _b.z() = All(Swizzle(_b, X, Y)); in emitCode()
41 _b.w() = Any(Swizzle(_b, X, Y, Z)); in emitCode()
42 Swizzle(_n, X, Y) = Atan(Swizzle(_n, X, Y)); in emitCode()
43 Swizzle(_n, Z, W, X) = Atan(Swizzle(_n, Y, Y, Y), Swizzle(_n, Z, Z, Z)); in emitCode()
48 Swizzle(_n, X, Y, Z) = Degrees(Swizzle(_n, X, Y, Z)); in emitCode()
49 _n.w() = Distance(Swizzle(_n, X, Z), Swizzle(_n, Y, W)); in emitCode()
50 _n.x() = Dot(Swizzle(_n, Y, Z, W), Swizzle(_n, Y, Z, W)); in emitCode()
51 Swizzle(_b, X, Y, Z) = Equal(Swizzle(_b, X, X, X), Swizzle(_b, W, W, W)); in emitCode()
52 Swizzle(_n, Y, Z) = Exp(Swizzle(_n, W, X)); in emitCode()
53 Swizzle(_n, Z, W) = Exp2(Swizzle(_n, X, Y)); in emitCode()
[all …]
DGrDSLFPTest_Swizzle.dsl.cpp31 _v = Half4(Swizzle(_v, X, Y), 1.0f, 1.0f); in emitCode()
34 _v = Half4(Swizzle(_v, X, Y, Z), 1.0f); in emitCode()
35 _v = Half4(Swizzle(_v, X, Y), 1.0f, 1.0f); in emitCode()
38 _v = Half4(1.0f, Swizzle(_v, Y, Z), 1.0f); in emitCode()
41 _v = Half4(Swizzle(_v, X, Y, Z), 1.0f); in emitCode()
42 _v = Swizzle(_v, W, W, W, W); in emitCode()
43 _v = Half4(Swizzle(_v, X, Y), 1.0f, 0.0f); in emitCode()
44 _v = Swizzle(_v, X, Z, Z, X); in emitCode()
48 _v = Half4(1.0f, Swizzle(_v, Y, Z, W)); in emitCode()
49 _v = Half4(0.0f, Swizzle(_v, Y, Z), 1.0f); in emitCode()
[all …]
DGrDSLFPTest_IfStatement.dsl.cpp38 If(Swizzle(_color, X, Y) == Swizzle(_color, Z, W), /*Then:*/ _color.w() = _one); in emitCode()
39 If(Swizzle(_color, X, Y) == Swizzle(_color, Z, W), /*Then:*/ Block(_color.x() = _color.w())); in emitCode()
40 If(_color.x() == _color.y(), /*Then:*/ _color = Swizzle(_color, W, X, W, W), /*Else:*/ _color = Swi… in emitCode()
41 …= 2.0f, /*Then:*/ Block(_color = Half4(-2.0f)), /*Else:*/ Block(_color = Swizzle(_color, Y, Y, W, … in emitCode()
42Swizzle(_color, X, X, X, X)), /*Else:*/ Block(_color = Swizzle(_color, Y, Y, Y, Y)))), /*Else:*/ B… in emitCode()
/external/libdrm/intel/tests/
Dgen6-3d.batch-ref.txt91 0x12300168: 0x00200810: Attrib Out 0, Attrib Swizzle enable, VUE read length 1, VUE read of…
98 … Attrib 1 (Override , Const Source 0, Swizzle Select 0, Source 0); Attrib 0 (Override , Const So…
99 … Attrib 3 (Override , Const Source 0, Swizzle Select 0, Source 0); Attrib 2 (Override , Const So…
100 … Attrib 5 (Override , Const Source 0, Swizzle Select 0, Source 0); Attrib 4 (Override , Const So…
101 … Attrib 7 (Override , Const Source 0, Swizzle Select 0, Source 0); Attrib 6 (Override , Const So…
102 … Attrib 9 (Override , Const Source 0, Swizzle Select 0, Source 0); Attrib 8 (Override , Const So…
103 … Attrib 11 (Override , Const Source 0, Swizzle Select 0, Source 0); Attrib 10 (Override , Const So…
104 … Attrib 13 (Override , Const Source 0, Swizzle Select 0, Source 0); Attrib 12 (Override , Const So…
105 … Attrib 15 (Override , Const Source 0, Swizzle Select 0, Source 0); Attrib 14 (Override , Const So…
214 0x12300354: 0x00600810: Attrib Out 1, Attrib Swizzle enable, VUE read length 1, VUE read of…
[all …]
/external/mesa3d/src/mesa/program/
Dprog_opt_constant_fold.c59 src.Swizzle = swiz; in src_reg_for_float()
74 src.Swizzle = swiz; in src_reg_for_vec4()
84 && (a->Swizzle == b->Swizzle) in src_regs_are_same()
97 data[0] = value[GET_SWZ(r->Swizzle, 0)].f; in get_value()
98 data[1] = value[GET_SWZ(r->Swizzle, 1)].f; in get_value()
99 data[2] = value[GET_SWZ(r->Swizzle, 2)].f; in get_value()
100 data[3] = value[GET_SWZ(r->Swizzle, 3)].f; in get_value()
153 inst->SrcReg[1].Swizzle = SWIZZLE_NOOP; in _mesa_constant_fold()
183 inst->SrcReg[1].Swizzle = SWIZZLE_NOOP; in _mesa_constant_fold()
185 inst->SrcReg[2].Swizzle = SWIZZLE_NOOP; in _mesa_constant_fold()
[all …]
Dprogramopt.c95 newInst[i].SrcReg[0].Swizzle = SWIZZLE_NOOP; in insert_mvp_dp4_code()
98 newInst[i].SrcReg[1].Swizzle = SWIZZLE_NOOP; in insert_mvp_dp4_code()
166 newInst[0].SrcReg[0].Swizzle = SWIZZLE_XXXX; in insert_mvp_mad_code()
169 newInst[0].SrcReg[1].Swizzle = SWIZZLE_NOOP; in insert_mvp_mad_code()
178 newInst[i].SrcReg[0].Swizzle = MAKE_SWIZZLE4(i,i,i,i); in insert_mvp_mad_code()
181 newInst[i].SrcReg[1].Swizzle = SWIZZLE_NOOP; in insert_mvp_mad_code()
184 newInst[1].SrcReg[2].Swizzle = SWIZZLE_NOOP; in insert_mvp_mad_code()
193 newInst[3].SrcReg[0].Swizzle = SWIZZLE_WWWW; in insert_mvp_mad_code()
196 newInst[3].SrcReg[1].Swizzle = SWIZZLE_NOOP; in insert_mvp_mad_code()
199 newInst[3].SrcReg[2].Swizzle = SWIZZLE_NOOP; in insert_mvp_mad_code()
[all …]
Dprog_instruction.c49 inst[i].SrcReg[0].Swizzle = SWIZZLE_NOOP; in _mesa_init_instructions()
51 inst[i].SrcReg[1].Swizzle = SWIZZLE_NOOP; in _mesa_init_instructions()
53 inst[i].SrcReg[2].Swizzle = SWIZZLE_NOOP; in _mesa_init_instructions()
230 GLuint swizzle = GET_SWZ(inst->SrcReg[i].Swizzle, chan); in _mesa_check_soa_dependencies()
/external/mesa3d/src/mesa/drivers/dri/r200/
Dr200_vertprog.c286 t_swizzle(GET_SWZ(src->Swizzle, 0)), in t_src()
287 t_swizzle(GET_SWZ(src->Swizzle, 1)), in t_src()
288 t_swizzle(GET_SWZ(src->Swizzle, 2)), in t_src()
289 t_swizzle(GET_SWZ(src->Swizzle, 3)), in t_src()
298 t_swizzle(GET_SWZ(src->Swizzle, 0)), in t_src_scalar()
299 t_swizzle(GET_SWZ(src->Swizzle, 0)), in t_src_scalar()
300 t_swizzle(GET_SWZ(src->Swizzle, 0)), in t_src_scalar()
301 t_swizzle(GET_SWZ(src->Swizzle, 0)), in t_src_scalar()
606 if (GET_SWZ(src[i].Swizzle, j) == SWIZZLE_W) { in r200_translate_vertex_program()
607 src[i].Swizzle &= ~(SWIZZLE_W << (j*3)); in r200_translate_vertex_program()
[all …]
/external/mesa3d/src/mesa/main/
Dformat_parser.py109 class Swizzle: class
148 swizzle = [Swizzle.__identity_str.index(c) for c in swizzle]
152 assert isinstance(s, int) and 0 <= s and s <= Swizzle.SWIZZLE_NONE
156 self.__list = swizzle + [Swizzle.SWIZZLE_NONE] * (4 - len(swizzle))
169 return ''.join(Swizzle.__identity_str[i] for i in self.__list)
180 assert idx >= Swizzle.SWIZZLE_X and idx <= Swizzle.SWIZZLE_NONE
181 if idx <= Swizzle.SWIZZLE_W:
204 assert isinstance(other, Swizzle)
205 return Swizzle(self[x] for x in other)
224 rev = [Swizzle.SWIZZLE_NONE] * 4
[all …]
/external/mesa3d/src/gallium/drivers/r300/compiler/tests/
Drc_test_helpers.c120 struct match_info Swizzle; member
160 tokens.Swizzle.String = src_str + matches[5].rm_so; in init_rc_normal_src()
161 tokens.Swizzle.Length = match_length(matches, 5); in init_rc_normal_src()
193 if (tokens.Swizzle.Length == 0) { in init_rc_normal_src()
194 src_reg->Swizzle = RC_SWIZZLE_XYZW; in init_rc_normal_src()
197 src_reg->Swizzle = RC_MAKE_SWIZZLE_SMEAR(RC_SWIZZLE_UNUSED); in init_rc_normal_src()
198 if (tokens.Swizzle.String[0] != '.') { in init_rc_normal_src()
202 for (i = 0; i < 4 && str_index < tokens.Swizzle.Length; in init_rc_normal_src()
204 if (tokens.Swizzle.String[str_index] == '-') { in init_rc_normal_src()
208 switch(tokens.Swizzle.String[str_index]) { in init_rc_normal_src()
[all …]
/external/mesa3d/src/gallium/drivers/r300/compiler/
Dradeon_dataflow_swizzles.c49 if (GET_SWZ(inst->U.I.SrcReg[src].Swizzle, chan) != RC_SWIZZLE_UNUSED) in rewrite_source()
70 SET_SWZ(mov->U.I.SrcReg[0].Swizzle, chan, RC_SWIZZLE_UNUSED); in rewrite_source()
72 phase_refmask |= 1 << GET_SWZ(mov->U.I.SrcReg[0].Swizzle, chan); in rewrite_source()
87 inst->U.I.SrcReg[src].Swizzle = 0; in rewrite_source()
91 SET_SWZ(inst->U.I.SrcReg[src].Swizzle, chan, in rewrite_source()
115 unsigned swz = GET_SWZ(reg->Swizzle, chan); in try_rewrite_constant()
125 new_swizzle = reg->Swizzle; in try_rewrite_constant()
135 unsigned chan_swz = GET_SWZ(reg->Swizzle, chan); in try_rewrite_constant()
327 swz3 = GET_SWZ(reg->Swizzle, 3); in try_rewrite_constant()
332 unsigned old_swz = GET_SWZ(reg->Swizzle, chan); in try_rewrite_constant()
[all …]
Dradeon_pair_translate.c46 inst->SrcReg[1].Swizzle = RC_SWIZZLE_1111; in final_rewrite()
67 inst->SrcReg[1].Swizzle = RC_SWIZZLE_1111; in final_rewrite()
69 inst->SrcReg[2].Swizzle = RC_SWIZZLE_0000; in final_rewrite()
74 inst->SrcReg[2].Swizzle = RC_SWIZZLE_0000; in final_rewrite()
137 unsigned int swz = GET_SWZ(src.Swizzle, j); in src_uses()
224 unsigned int swz = GET_SWZ(inst->SrcReg[i].Swizzle, j); in set_pair_instruction()
242 pair->RGB.Arg[i].Swizzle = in set_pair_instruction()
243 rc_init_swizzle(inst->SrcReg[i].Swizzle, 3); in set_pair_instruction()
252 swz = rc_get_scalar_src_swz(inst->SrcReg[i].Swizzle); in set_pair_instruction()
254 swz = GET_SWZ(inst->SrcReg[i].Swizzle, 3); in set_pair_instruction()
[all …]
Dradeon_compiler_util.c203 sub->Arg[i].Swizzle = in rc_pair_rewrite_writemask()
204 rc_adjust_channels(sub->Arg[i].Swizzle, in rc_pair_rewrite_writemask()
215 src->Swizzle = rc_adjust_channels(src->Swizzle, *conversion_swizzle); in normal_rewrite_writemask_cb()
292 tmp.Swizzle = 0; in lmul_swizzle()
297 tmp.Swizzle |= GET_SWZ(srcreg.Swizzle, swz) << (i*3); in lmul_swizzle()
300 tmp.Swizzle |= swz << (i*3); in lmul_swizzle()
309 reg->Swizzle = RC_SWIZZLE_XYZW; in reset_srcreg()
408 rc_source_type_swz(src->Swizzle)); in can_use_presub_read_cb()
451 src_type0 = rc_source_type_swz(presub_src0->Swizzle); in rc_inst_can_use_presub()
458 src_type1 = rc_source_type_swz(presub_src1->Swizzle); in rc_inst_can_use_presub()
[all …]
Dradeon_program_tex.c41 reg.Swizzle = combine_swizzles(RC_SWIZZLE_0000, in shadow_fail_value()
52 reg.Swizzle = combine_swizzles(RC_SWIZZLE_1111, in shadow_pass_value()
96 inst_rcp->U.I.SrcReg[0].Swizzle = in projective_divide()
97 RC_MAKE_SWIZZLE_SMEAR(GET_SWZ(inst->U.I.SrcReg[0].Swizzle, 3)); in projective_divide()
106 inst_mul->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_WWWW; in projective_divide()
185 inst_rcp->U.I.SrcReg[0].Swizzle = in radeonTransformTEX()
186 RC_MAKE_SWIZZLE_SMEAR(GET_SWZ(inst->U.I.SrcReg[0].Swizzle, 3)); in radeonTransformTEX()
197 inst_mul->U.I.SrcReg[0].Swizzle = in radeonTransformTEX()
198 RC_MAKE_SWIZZLE_SMEAR(GET_SWZ(inst->U.I.SrcReg[0].Swizzle, 2)); in radeonTransformTEX()
202 inst_mul->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_WWWW; in radeonTransformTEX()
[all …]
Dr500_fragprog.c99 if (GET_SWZ(inst_if->U.I.SrcReg[0].Swizzle, 0) == RC_SWIZZLE_X) { in r500_transform_IF()
115 inst_mov->U.I.SrcReg[0].Swizzle = combine_swizzles4( in r500_transform_IF()
116 inst_mov->U.I.SrcReg[0].Swizzle, in r500_transform_IF()
120 inst_mov->U.I.SrcReg[0].Swizzle = combine_swizzles4( in r500_transform_IF()
121 inst_mov->U.I.SrcReg[0].Swizzle, in r500_transform_IF()
175 inst_if->U.I.SrcReg[0].Swizzle = RC_MAKE_SWIZZLE( in r500_transform_IF()
197 if (opcode == RC_OPCODE_KIL && (reg.Swizzle != RC_SWIZZLE_XYZW || reg.Negate != RC_MASK_NONE)) in r500_swizzle_is_native()
201 unsigned int swz = GET_SWZ(reg.Swizzle, i); in r500_swizzle_is_native()
217 if (reg.Swizzle == RC_SWIZZLE_XYZW && !reg.Abs && !reg.Negate) in r500_swizzle_is_native()
227 unsigned int swz = GET_SWZ(reg.Swizzle, i); in r500_swizzle_is_native()
[all …]
Dradeon_optimize.c59 combine.Negate = swizzle_mask(outer.Swizzle, inner.Negate); in chain_srcregs()
62 combine.Swizzle = combine_swizzles(inner.Swizzle, outer.Swizzle); in chain_srcregs()
74 rc_swizzle_to_writemask(src->Swizzle), in copy_propagate_scan_read()
113 && (rc_swizzle_to_writemask(src->Swizzle) & sc_data->Mask)) { in src_clobbered_reads_cb()
204 unsigned int swz = GET_SWZ(src.Swizzle, chan); in is_src_uniform_constant()
282 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_0000; in constant_folding_mul()
295 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_0000; in constant_folding_mul()
340 if (GET_SWZ(inst->U.I.SrcReg[src].Swizzle, chan) <= 3) in constant_folding()
362 unsigned int swz = GET_SWZ(newsrc.Swizzle, chan); in constant_folding()
386 SET_SWZ(newsrc.Swizzle, chan, newswz); in constant_folding()
[all …]
Dradeon_compiler.c154 inst->U.I.SrcReg[i].Swizzle = combine_swizzles(new_input.Swizzle, inst->U.I.SrcReg[i].Swizzle); in rc_move_input()
219 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_XYZW; in rc_copy_output()
228 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_XYZW; in rc_copy_output()
259 inst_rcp->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_WWWW; in rc_transform_fragment_wpos()
273 inst_mul->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_WWWW; in rc_transform_fragment_wpos()
285 inst_mad->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_XYZ0; in rc_transform_fragment_wpos()
288 inst_mad->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_XYZ0; in rc_transform_fragment_wpos()
291 inst_mad->U.I.SrcReg[2].Swizzle = RC_SWIZZLE_XYZ0; in rc_transform_fragment_wpos()
338 inst_add->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_1111; in rc_transform_fragment_face()
342 inst_add->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_XXXX; in rc_transform_fragment_face()
Dr3xx_vertprog.c147 t_swizzle(GET_SWZ(src->Swizzle, 0)), in t_src()
148 t_swizzle(GET_SWZ(src->Swizzle, 1)), in t_src()
149 t_swizzle(GET_SWZ(src->Swizzle, 2)), in t_src()
150 t_swizzle(GET_SWZ(src->Swizzle, 3)), in t_src()
162 unsigned int swz = rc_get_scalar_src_swz(src->Swizzle); in t_src_scalar()
251 …S_SRC_OPERAND(t_src_index(vp, &vpi->SrcReg[0]), t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, 0)), // X in ei_lit()
252 t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, 3)), // W in ei_lit()
254 t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, 1)), // Y in ei_lit()
258 …S_SRC_OPERAND(t_src_index(vp, &vpi->SrcReg[0]), t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, 1)), // Y in ei_lit()
259 t_swizzle(GET_SWZ(vpi->SrcReg[0].Swizzle, 3)), // W in ei_lit()
[all …]
Dradeon_vert_fc.c46 src->Swizzle = RC_MAKE_SWIZZLE(RC_SWIZZLE_UNUSED, RC_SWIZZLE_UNUSED, in build_pred_src()
133 new_inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_0000; in lower_bgnloop()
153 new_inst->U.I.SrcReg[1].Swizzle = RC_SWIZZLE_0000; in lower_bgnloop()
167 inst->U.I.SrcReg[0].Swizzle = RC_SWIZZLE_0000; in lower_brk()
222 swz = rc_get_scalar_src_swz(inst->U.I.SrcReg[1].Swizzle); in lower_if()
225 inst->U.I.SrcReg[1].Swizzle = RC_MAKE_SWIZZLE(RC_SWIZZLE_UNUSED, in lower_if()
Dr300_fragprog_swizzle.c123 unsigned int swz = GET_SWZ(reg.Swizzle, j); in r300_swizzle_is_native()
136 if (GET_SWZ(reg.Swizzle, j) != RC_SWIZZLE_UNUSED) in r300_swizzle_is_native()
142 sd = lookup_native_swizzle(reg.Swizzle); in r300_swizzle_is_native()
169 swz = GET_SWZ(src.Swizzle, comp); in r300_swizzle_split()
/external/skia/src/sksl/ir/
DSkSLSwizzle.cpp16 std::unique_ptr<Expression> Swizzle::Convert(const Context& context, in Convert()
66 std::unique_ptr<Expression> expr = Swizzle::Make(context, std::move(base), maskComponents); in Convert()
131 return Swizzle::Make(context, std::move(expr), swizzleComponents); in Convert()
134 std::unique_ptr<Expression> Swizzle::Make(const Context& context, in Make()
175 if (expr->is<Swizzle>()) { in Make()
176 Swizzle& base = expr->as<Swizzle>(); in Make()
184 return Swizzle::Make(context, std::move(base.base()), combined); in Make()
313 newArgs.push_back(Swizzle::Make(context, std::move(newArg), in Make()
330 return std::make_unique<Swizzle>(context, std::move(expr), components); in Make()
DSkSLSwizzle.h23 struct Swizzle final : public Expression {
26 Swizzle(const Context& context, std::unique_ptr<Expression> base, in Swizzle() function
65 return std::unique_ptr<Expression>(new Swizzle(&this->type(), this->base()->clone(), in clone()
78 Swizzle(const Type* type, std::unique_ptr<Expression> base, const ComponentArray& components) in Swizzle() function
/external/mesa3d/src/gallium/drivers/r600/sfn/
Dsfn_value_gpr.h77 using Swizzle = std::array<uint32_t,4>;
90 void swizzle(const Swizzle& swz);
187 inline GPRVector::Swizzle swizzle_from_comps(unsigned ncomp) in swizzle_from_comps()
189 GPRVector::Swizzle swz = {0,1,2,3}; in swizzle_from_comps()
195 inline GPRVector::Swizzle swizzle_from_mask(unsigned mask) in swizzle_from_mask()
197 GPRVector::Swizzle swz; in swizzle_from_mask()
/external/skia/src/sksl/dsl/
DDSLCore.cpp128 static DSLExpression Swizzle(DSLExpression base, SkSL::SwizzleComponent::Type a, in Swizzle() function in SkSL::dsl::DSLCore
130 return DSLExpression(Swizzle::Convert(DSLWriter::Context(), base.release(), in Swizzle()
135 static DSLExpression Swizzle(DSLExpression base, in Swizzle() function in SkSL::dsl::DSLCore
139 return DSLExpression(Swizzle::Convert(DSLWriter::Context(), base.release(), in Swizzle()
144 static DSLExpression Swizzle(DSLExpression base, in Swizzle() function in SkSL::dsl::DSLCore
149 return DSLExpression(Swizzle::Convert(DSLWriter::Context(), base.release(), in Swizzle()
154 static DSLExpression Swizzle(DSLExpression base, in Swizzle() function in SkSL::dsl::DSLCore
160 return DSLExpression(Swizzle::Convert(DSLWriter::Context(), base.release(), in Swizzle()
466 DSLExpression Swizzle(DSLExpression base, SkSL::SwizzleComponent::Type a, in Swizzle() function
468 return DSLCore::Swizzle(std::move(base), a, pos); in Swizzle()
[all …]
DDSLExpression.cpp117 return Swizzle(this->release(), X, pos); in x()
121 return Swizzle(this->release(), Y, pos); in y()
125 return Swizzle(this->release(), Z, pos); in z()
129 return Swizzle(this->release(), W, pos); in w()
133 return Swizzle(this->release(), R, pos); in r()
137 return Swizzle(this->release(), G, pos); in g()
141 return Swizzle(this->release(), B, pos); in b()
145 return Swizzle(this->release(), A, pos); in a()

12345678