Lines Matching refs:SkPoint
16 static bool nearly_equal(const SkPoint& a, const SkPoint& b) {
26 const SkPoint src[] = {
32 SkPoint dst[13];
41 SkPoint pts[7];
65 SkPoint pts[4] = {{rand.nextF(), rand.nextF()}, {rand.nextF(), rand.nextF()},
68 SkPoint allChops[4 + SK_ARRAY_COUNT(chopTs)*3];
73 SkPoint expectedPt;
86 SkPoint localChops[10];
108 SkPoint oneChops[4 + SK_ARRAY_COUNT(ones)*3];
132 SkPoint pts[3];
139 SkPoint r0;
141 SkPoint r1 = SkEvalQuadAt(pts, t);
155 SkPoint p0, p1;
171 SkPoint pts[3];
191 SkPoint pts[] = {
211 SkPoint pts[] = {
230 static void test_this_conic_to_quad(skiatest::Reporter* r, const SkPoint pts[3], SkScalar w) {
232 const SkPoint* qpts = quadder.computeQuads(pts, w, 0.25);
246 const SkPoint triples[] = {
252 const int N = sizeof(triples) / sizeof(SkPoint);
255 const SkPoint* pts = &triples[i];
267 SkPoint pts[] = {
288 const std::array<SkPoint, 4>& bezierPoints, SkCubicType expectedType,
326 SkPoint points[] = {{x1, y1}, {x2, y1}, {x2, y2}, {x1, y2}};
327 std::array<SkPoint, 4> bezier;
365 static std::array<SkPoint, 4> kSerpentines[] = {
372 static std::array<SkPoint, 4> kLoops[] = {
379 static std::array<SkPoint, 4> kLinearCubics[] = {
429 static std::array<SkPoint, 4> kCusps[] = {
437 std::array<SkPoint, 4> noCusps[] = {
457 static void test_chop_quad_at_midtangent(skiatest::Reporter* reporter, const SkPoint pts[3]) {
460 SkPoint mapped[3];
463 SkPoint chopped[5];
472 static void test_chop_cubic_at_midtangent(skiatest::Reporter* reporter, const SkPoint pts[4],
482 SkPoint mapped[4];
485 SkPoint chopped[7];
514 static std::array<SkPoint, 3> kQuads[] = {
522 SkPoint lerp(const SkPoint& a, const SkPoint& b, float t) {
527 static SkPoint kFlatCubic[4] = {{0, 0}, {0, 1}, {0, 2}, {0, 3}};
530 static SkPoint kFlatCubic180_1[4] = {{0, 0}, {1, 0}, {3, 0}, {2, 0}};
534 static SkPoint kFlatCubic180_2[4] = {{0, 1}, {0, 0}, {0, 2}, {0, 3}};
538 static SkPoint kFlatCubic360[4] = {{0, 1}, {0, 0}, {0, 3}, {0, 2}};
542 static SkPoint kSquare180[4] = {{0, 0}, {0, 1}, {1, 1}, {1, 0}};
546 auto checkQuadRotation = [=](const SkPoint pts[3], float expectedRotation) {
550 SkPoint cubic1[4] = {pts[0], pts[0], pts[1], pts[2]};
554 SkPoint cubic2[4] = {pts[0], pts[1], pts[1], pts[2]};
558 SkPoint cubic3[4] = {pts[0], pts[1], pts[2], pts[2]};
563 static SkPoint kFlatQuad[4] = {{0, 0}, {0, 1}, {0, 2}};
566 static SkPoint kFlatQuad180_1[4] = {{1, 0}, {0, 0}, {2, 0}};
569 static SkPoint kFlatQuad180_2[4] = {{0, 0}, {0, 2}, {0, 1}};
572 static SkPoint kTri120[3] = {{0, 0}, {.5f, std::sqrt(3.f)/2}, {1, 0}};
577 SkPoint chops[10];
599 SkPoint asCubic[4] = {
604 static const SkPoint kExactQuad[4] = {{0,0}, {6,2}, {10,2}, {12,0}};
608 static const SkPoint kExactCuspAtInf[4] = {{0,0}, {1,0}, {0,1}, {1,1}};
617 SkPoint pts[5];
637 const SkPoint cubic[] = {