• Home
  • Raw
  • Download

Lines Matching refs:SkPath

44     SkPath path;  in test_add_rrect()
51 SkPath path; in test_skbug_3469()
76 static void make_path_crbug364224(SkPath* path) { in make_path_crbug364224()
100 static void make_path_crbug364224_simplified(SkPath* path) { in make_path_crbug364224_simplified()
109 SkPath path; in test_sect_with_horizontal_needs_pinning()
121 SkPath path; in test_path_crbug364224()
133 static void test_draw_AA_path(int width, int height, const SkPath& path) { in test_draw_AA_path()
143 SkPath path; in test_fuzz_crbug_638223()
152 SkPath path; in test_fuzz_crbug_643933()
167 SkPath path; in test_fuzz_crbug_647922()
180 SkPath path; in test_fuzz_crbug_662780()
204 SkPath path; in test_mask_overflow()
218 SkPath path; in test_fuzz_crbug_668907()
231 static void make_path_crbugskia2820(SkPath* path, skiatest::Reporter* reporter) { in make_path_crbugskia2820()
245 SkPath path; in test_path_crbugskia2820()
254 SkPath path; in test_path_crbugskia5995()
262 static void make_path0(SkPath* path) { in make_path0()
273 static void make_path1(SkPath* path) { in make_path1()
277 typedef void (*PathProc)(SkPath*);
296 SkPath path; in test_path_to_region()
315 SkPath path; in test_path_close_issue1474()
363 SkPath a, b; in test_gen_id()
387 SkPath c(a); in test_gen_id()
412 SkPath path; in test_bad_cubic_crbug234190()
428 SkPath path; in test_bad_cubic_crbug229478()
436 SkPath dst; in test_bad_cubic_crbug229478()
442 static void build_path_170666(SkPath& path) { in build_path_170666()
522 static void build_path_simple_170666(SkPath& path) { in build_path_simple_170666()
531 SkPath path; in test_crbug_170666()
542 SkPath smallPath; in test_tiny_path_convexity()
545 SkPath largePath; in test_tiny_path_convexity()
602 SkPath path; in test_crbug_613918()
613 SkPath path; in test_addrect()
641 SkPath path; in test_addrect_isfinite()
660 static void build_big_path(SkPath* path, bool reducedCase) { in build_big_path()
687 SkPath path; in test_clipped_cubic()
708 SkPath path; in test_bounds_crbug_513799()
738 SkPath path; in test_fuzz_crbug_627414()
756 SkPath path; in test_tricky_cubic()
765 SkPath path; in test_isfinite_after_transform()
790 static void add_corner_arc(SkPath* path, const SkRect& rect, in add_corner_arc()
820 static void make_arb_round_rect(SkPath* path, const SkRect& r, in make_arb_round_rect()
849 SkPath temp; in test_arb_round_rect_is_convex()
876 SkPath temp; in test_arb_zero_rad_round_rect_is_rect()
925 SkPath path; in test_path_isfinite()
950 SkPath path; in test_islastcontourclosed()
973 static void test_poly(skiatest::Reporter* reporter, const SkPath& path, in test_poly()
975 SkPath::RawIter iter(path); in test_poly()
982 case SkPath::kMove_Verb: in test_poly()
988 case SkPath::kLine_Verb: in test_poly()
993 case SkPath::kQuad_Verb: in test_poly()
996 case SkPath::kConic_Verb: in test_poly()
999 case SkPath::kCubic_Verb: in test_poly()
1002 case SkPath::kClose_Verb: in test_poly()
1008 case SkPath::kDone_Verb: in test_poly()
1027 SkPath path; in test_addPoly()
1059 static void check_direction(skiatest::Reporter* reporter, const SkPath& path, in check_direction()
1064 SkPath copy(path); // we make a copy so that we don't cache the result on the passed in path. in check_direction()
1076 SkPath path; in test_direction()
1132 path.addCircle(0, 0, SkIntToScalar(2), SkPath::kCW_Direction); in test_direction()
1133 path.addCircle(0, 0, SkIntToScalar(1), SkPath::kCCW_Direction); in test_direction()
1137 path.addCircle(0, 0, SkIntToScalar(1), SkPath::kCW_Direction); in test_direction()
1138 path.addCircle(0, 0, SkIntToScalar(2), SkPath::kCCW_Direction); in test_direction()
1158 REPORTER_ASSERT(reporter, SkPath::kConvex_Convexity == path.getConvexity()); in test_direction()
1162 static void add_rect(SkPath* path, const SkRect& r) { in add_rect()
1178 SkPath path0, path1; in test_bounds()
1188 SkPath path; in stroke_cubic()
1196 SkPath fill; in stroke_cubic()
1223 static void check_close(skiatest::Reporter* reporter, const SkPath& path) { in check_close()
1225 SkPath::Iter iter(path, SkToBool(i)); in check_close()
1228 SkPath::Verb v; in check_close()
1232 while (SkPath::kDone_Verb != (v = iter.next(pts))) { in check_close()
1234 case SkPath::kMove_Verb: in check_close()
1238 case SkPath::kClose_Verb: in check_close()
1253 SkPath closePt; in test_close()
1258 SkPath openPt; in test_close()
1262 SkPath empty; in test_close()
1267 SkPath rect; in test_close()
1273 SkPath quad; in test_close()
1279 SkPath cubic; in test_close()
1286 SkPath line; in test_close()
1293 SkPath rect2; in test_close()
1301 SkPath oval3; in test_close()
1309 SkPath moves; in test_close()
1319 static void check_convexity(skiatest::Reporter* reporter, const SkPath& path, in check_convexity()
1320 SkPath::Convexity expected) { in check_convexity()
1321 SkPath copy(path); // we make a copy so that we don't cache the result on the passed in path. in check_convexity()
1322 SkPath::Convexity c = copy.getConvexity(); in check_convexity()
1326 SkPath::Iter iter(path, true); in check_convexity()
1329 while (SkPath::kMove_Verb == iter.next(pts, false, false)) { in check_convexity()
1338 REPORTER_ASSERT(reporter, isConvex == (SkPath::kConvex_Convexity == expected)); in check_convexity()
1344 SkPath tinyConvexPolygon; in test_path_crbug389050()
1351 check_convexity(reporter, tinyConvexPolygon, SkPath::COLINEAR_DIAGONAL_CONVEXITY); in test_path_crbug389050()
1362 SkPath platTriangle; in test_path_crbug389050()
1380 SkPath pt; in test_convexity2()
1383 check_convexity(reporter, pt, SkPath::kConvex_Convexity); in test_convexity2()
1386 SkPath line; in test_convexity2()
1390 check_convexity(reporter, line, SkPath::kConvex_Convexity); in test_convexity2()
1393 SkPath triLeft; in test_convexity2()
1398 check_convexity(reporter, triLeft, SkPath::kConvex_Convexity); in test_convexity2()
1401 SkPath triRight; in test_convexity2()
1406 check_convexity(reporter, triRight, SkPath::kConvex_Convexity); in test_convexity2()
1409 SkPath square; in test_convexity2()
1415 check_convexity(reporter, square, SkPath::kConvex_Convexity); in test_convexity2()
1418 SkPath redundantSquare; in test_convexity2()
1432 check_convexity(reporter, redundantSquare, SkPath::kConvex_Convexity); in test_convexity2()
1435 SkPath bowTie; in test_convexity2()
1449 check_convexity(reporter, bowTie, SkPath::kConcave_Convexity); in test_convexity2()
1452 SkPath spiral; in test_convexity2()
1461 check_convexity(reporter, spiral, SkPath::kConcave_Convexity); in test_convexity2()
1464 SkPath dent; in test_convexity2()
1471 check_convexity(reporter, dent, SkPath::kConcave_Convexity); in test_convexity2()
1475 SkPath strokedSin; in test_convexity2()
1488 check_convexity(reporter, strokedSin, SkPath::COLINEAR_DIAGONAL_CONVEXITY); in test_convexity2()
1492 SkPath degenerateConcave; in test_convexity2()
1499 check_convexity(reporter, degenerateConcave, SkPath::kConcave_Convexity); in test_convexity2()
1503 SkPath badFirstVector; in test_convexity2()
1514 check_convexity(reporter, badFirstVector, SkPath::kConcave_Convexity); in test_convexity2()
1518 SkPath doubleback; in test_convexity_doubleback()
1520 check_convexity(reporter, doubleback, SkPath::kConvex_Convexity); in test_convexity_doubleback()
1522 check_convexity(reporter, doubleback, SkPath::COLINEAR_DIAGONAL_CONVEXITY); in test_convexity_doubleback()
1525 check_convexity(reporter, doubleback, SkPath::kConvex_Convexity); in test_convexity_doubleback()
1527 check_convexity(reporter, doubleback, SkPath::kConvex_Convexity); in test_convexity_doubleback()
1529 check_convexity(reporter, doubleback, SkPath::kConvex_Convexity); in test_convexity_doubleback()
1532 check_convexity(reporter, doubleback, SkPath::COLINEAR_DIAGONAL_CONVEXITY); in test_convexity_doubleback()
1535 check_convexity(reporter, doubleback, SkPath::kConvex_Convexity); in test_convexity_doubleback()
1537 check_convexity(reporter, doubleback, SkPath::kConvex_Convexity); in test_convexity_doubleback()
1540 static void check_convex_bounds(skiatest::Reporter* reporter, const SkPath& p, in check_convex_bounds()
1545 SkPath p2(p); in check_convex_bounds()
1549 SkPath other; in check_convex_bounds()
1555 static void setFromString(SkPath* path, const char str[]) { in setFromString()
1575 SkPath path; in test_convexity()
1577 check_convexity(reporter, path, SkPath::kConvex_Convexity); in test_convexity()
1579 check_convexity(reporter, path, SkPath::kConvex_Convexity); in test_convexity()
1581 check_convexity(reporter, path, SkPath::kConcave_Convexity); in test_convexity()
1584 path.addRect(0, 0, SkIntToScalar(10), SkIntToScalar(10), SkPath::kCCW_Direction); in test_convexity()
1585 check_convexity(reporter, path, SkPath::kConvex_Convexity); in test_convexity()
1589 path.addRect(0, 0, SkIntToScalar(10), SkIntToScalar(10), SkPath::kCW_Direction); in test_convexity()
1590 check_convexity(reporter, path, SkPath::kConvex_Convexity); in test_convexity()
1595 check_convexity(reporter, path, SkPath::COLINEAR_DIAGONAL_CONVEXITY); in test_convexity()
1599 SkPath::Convexity fExpectedConvexity; in test_convexity()
1602 { "", SkPath::kConvex_Convexity, SkPathPriv::kUnknown_FirstDirection }, in test_convexity()
1603 { "0 0", SkPath::kConvex_Convexity, SkPathPriv::kUnknown_FirstDirection }, in test_convexity()
1604 { "0 0 10 10", SkPath::kConvex_Convexity, SkPathPriv::kUnknown_FirstDirection }, in test_convexity()
1605 … { "0 0 10 10 20 20 0 0 10 10", SkPath::kConcave_Convexity, SkPathPriv::kUnknown_FirstDirection }, in test_convexity()
1606 { "0 0 10 10 10 20", SkPath::kConvex_Convexity, SkPathPriv::kCW_FirstDirection }, in test_convexity()
1607 { "0 0 10 10 10 0", SkPath::kConvex_Convexity, SkPathPriv::kCCW_FirstDirection }, in test_convexity()
1608 { "0 0 10 10 10 0 0 10", SkPath::kConcave_Convexity, kDontCheckDir }, in test_convexity()
1609 { "0 0 10 0 0 10 -10 -10", SkPath::kConcave_Convexity, SkPathPriv::kCW_FirstDirection }, in test_convexity()
1619 SkPath copy(path); in test_convexity()
1676 check_convexity(reporter, path, SkPath::kUnknown_Convexity); in test_convexity()
1698 check_convexity(reporter, path, SkPath::kConvex_Convexity); in test_convexity()
1700SkPath copy(path); // we make a copy so that we don't cache the result on the passed in path. in test_convexity()
1701 SkPath::Convexity c = copy.getConvexity(); in test_convexity()
1702 REPORTER_ASSERT(reporter, SkPath::kUnknown_Convexity == c in test_convexity()
1703 || SkPath::kConcave_Convexity == c); in test_convexity()
1733 check_convexity(reporter, path, SkPath::kConvex_Convexity); in test_convexity()
1735SkPath copy(path); // we make a copy so that we don't cache the result on the passed in path. in test_convexity()
1736 SkPath::Convexity c = copy.getConvexity(); in test_convexity()
1737 REPORTER_ASSERT(reporter, SkPath::kUnknown_Convexity == c in test_convexity()
1738 || SkPath::kConcave_Convexity == c); in test_convexity()
1751 check_convexity(reporter, path, SkPath::kConcave_Convexity); in test_convexity()
1756 SkPath path; in test_isLine()
1806 SkPath path; in test_conservativelyContains()
1907 SkPath::Direction dir = d ? SkPath::kCCW_Direction : SkPath::kCW_Direction; in test_conservativelyContains()
2036 SkPath path; in test_isRect_open_close()
2138 SkPath path; in test_isRect()
2151 SkPath::Direction direction; in test_isRect()
2164 for (auto d : {SkPath::kCW_Direction, SkPath::kCCW_Direction}) { in test_isRect()
2166 SkPath::Direction direction = d; in test_isRect()
2177 SkPath path1; in test_isRect()
2232 static void check_simple_closed_rect(skiatest::Reporter* reporter, const SkPath& path, in check_simple_closed_rect()
2233 const SkRect& rect, SkPath::Direction dir, unsigned start) { in check_simple_closed_rect()
2235 SkPath::Direction d = SkPath::kCCW_Direction; in check_simple_closed_rect()
2247 SkPath::Direction d = SkPath::kCCW_Direction; in test_is_simple_closed_rect()
2252 SkPath path; in test_is_simple_closed_rect()
2254 for (auto dir : {SkPath::kCCW_Direction, SkPath::kCW_Direction}) { in test_is_simple_closed_rect()
2255 SkPath path; in test_is_simple_closed_rect()
2260 SkPath path2 = path; in test_is_simple_closed_rect()
2271 SkPath::RawIter iter(path); in test_is_simple_closed_rect()
2272 SkPath::Verb v; in test_is_simple_closed_rect()
2275 while ((v = iter.next(verbPts)) != SkPath::kDone_Verb) { in test_is_simple_closed_rect()
2277 case SkPath::kMove_Verb: in test_is_simple_closed_rect()
2281 case SkPath::kLine_Verb: in test_is_simple_closed_rect()
2311 SkPath::Direction swapDir = (dir == SkPath::kCW_Direction) in test_is_simple_closed_rect()
2312 ? SkPath::kCCW_Direction in test_is_simple_closed_rect()
2313 : SkPath::kCW_Direction; in test_is_simple_closed_rect()
2335 SkPath::Direction dir; in test_is_simple_closed_rect()
2436 SkPath path; in test_isNestedFillRects()
2438 path.addRect(-1, -1, 2, 2, SkPath::kCW_Direction); in test_isNestedFillRects()
2448 path.addRect(-1, -1, 2, 2, SkPath::kCCW_Direction); in test_isNestedFillRects()
2455 SkPath::Direction computedDirs[2]; in test_isNestedFillRects()
2475 SkPath path1; in test_isNestedFillRects()
2477 path1.addRect(-1, -1, 2, 2, SkPath::kCW_Direction); in test_isNestedFillRects()
2486 path1.addRect(-1, -1, 2, 2, SkPath::kCCW_Direction); in test_isNestedFillRects()
2493 path1.addRect(-1, -1, 2, 2, SkPath::kCW_Direction); in test_isNestedFillRects()
2504 path1.addRect(-1, -1, 2, 2, SkPath::kCCW_Direction); in test_isNestedFillRects()
2511 path1.addRect(-1, -1, 2, 2, SkPath::kCW_Direction); in test_isNestedFillRects()
2519 path1.addRect(-1, -1, 2, 2, SkPath::kCCW_Direction); in test_isNestedFillRects()
2526 path1.addRect(-1, -1, 2, 2, SkPath::kCW_Direction); in test_isNestedFillRects()
2537 path1.addRect(-1, -1, 2, 2, SkPath::kCCW_Direction); in test_isNestedFillRects()
2544 path1.addRect(-1, -1, 2, 2, SkPath::kCW_Direction); in test_isNestedFillRects()
2555 path1.addRect(-1, -1, 2, 2, SkPath::kCCW_Direction); in test_isNestedFillRects()
2561 path1.addRect(1, 1, 3, 3, SkPath::kCW_Direction); in test_isNestedFillRects()
2562 path1.addRect(2, 2, 4, 4, SkPath::kCW_Direction); in test_isNestedFillRects()
2567 SkPath path; in test_isNestedFillRects()
2581 SkPath src, dst; in test_isNestedFillRects()
2582 src.addRect(1, 1, 7, 7, SkPath::kCW_Direction); in test_isNestedFillRects()
2591 const SkPath& p) { in write_and_read_back()
2599 SkPath readBack; in write_and_read_back()
2608 SkPath::Direction dir0, dir1; in write_and_read_back()
2632 SkPath p; in test_flattening()
2654 SkPath p2; in test_flattening()
2662 SkPath tooShort; in test_flattening()
2673 SkPath oval; in test_flattening()
2682 SkPath p; in test_transform()
2708 SkPath p1; in test_transform()
2718 SkPath p1; // Leave p1 non-unique (i.e., the empty path) in test_transform()
2735 SkPath p1; in test_transform()
2750 p.addCircle(0, 0, 1, SkPath::kCW_Direction); in test_transform()
2755 SkPath p1; in test_transform()
2767 SkPath p1; in test_transform()
2777 SkPath p1; in test_transform()
2786 SkPath p; in test_zero_length_paths()
2793 const SkPath::Verb* resultVerbs; in test_zero_length_paths()
2797 static const SkPath::Verb resultVerbs1[] = { SkPath::kMove_Verb }; in test_zero_length_paths()
2798 static const SkPath::Verb resultVerbs2[] = { SkPath::kMove_Verb, SkPath::kMove_Verb }; in test_zero_length_paths()
2799 static const SkPath::Verb resultVerbs3[] = { SkPath::kMove_Verb, SkPath::kClose_Verb }; in test_zero_length_paths()
2800 …static const SkPath::Verb resultVerbs4[] = { SkPath::kMove_Verb, SkPath::kClose_Verb, SkPath::kMov… in test_zero_length_paths()
2801 static const SkPath::Verb resultVerbs5[] = { SkPath::kMove_Verb, SkPath::kLine_Verb }; in test_zero_length_paths()
2802 …static const SkPath::Verb resultVerbs6[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kMove… in test_zero_length_paths()
2803 …static const SkPath::Verb resultVerbs7[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kClos… in test_zero_length_paths()
2804 static const SkPath::Verb resultVerbs8[] = { in test_zero_length_paths()
2805SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kClose_Verb, SkPath::kMove_Verb, SkPath::kLine_Ver… in test_zero_length_paths()
2807 static const SkPath::Verb resultVerbs9[] = { SkPath::kMove_Verb, SkPath::kQuad_Verb }; in test_zero_length_paths()
2808 …static const SkPath::Verb resultVerbs10[] = { SkPath::kMove_Verb, SkPath::kQuad_Verb, SkPath::kMov… in test_zero_length_paths()
2809 …static const SkPath::Verb resultVerbs11[] = { SkPath::kMove_Verb, SkPath::kQuad_Verb, SkPath::kClo… in test_zero_length_paths()
2810 static const SkPath::Verb resultVerbs12[] = { in test_zero_length_paths()
2811SkPath::kMove_Verb, SkPath::kQuad_Verb, SkPath::kClose_Verb, SkPath::kMove_Verb, SkPath::kQuad_Ver… in test_zero_length_paths()
2813 static const SkPath::Verb resultVerbs13[] = { SkPath::kMove_Verb, SkPath::kCubic_Verb }; in test_zero_length_paths()
2814 …static const SkPath::Verb resultVerbs14[] = { SkPath::kMove_Verb, SkPath::kCubic_Verb, SkPath::kMo… in test_zero_length_paths()
2815 …static const SkPath::Verb resultVerbs15[] = { SkPath::kMove_Verb, SkPath::kCubic_Verb, SkPath::kCl… in test_zero_length_paths()
2816 static const SkPath::Verb resultVerbs16[] = { in test_zero_length_paths()
2817SkPath::kMove_Verb, SkPath::kCubic_Verb, SkPath::kClose_Verb, SkPath::kMove_Verb, SkPath::kCubic_V… in test_zero_length_paths()
2857 SkPath fPath;
2861 #define kCurveSegmentMask (SkPath::kQuad_SegmentMask | SkPath::kCubic_SegmentMask)
2864 SkPath p, p2; in test_segment_masks()
2868 REPORTER_ASSERT(reporter, SkPath::kQuad_SegmentMask == p.getSegmentMasks()); in test_segment_masks()
2881 REPORTER_ASSERT(reporter, SkPath::kCubic_SegmentMask == p.getSegmentMasks()); in test_segment_masks()
2889 SkPath p; in test_iter()
2893 SkPath::Iter noPathIter; in test_iter()
2894 REPORTER_ASSERT(reporter, noPathIter.next(pts) == SkPath::kDone_Verb); in test_iter()
2898 REPORTER_ASSERT(reporter, noPathIter.next(pts) == SkPath::kDone_Verb); in test_iter()
2902 REPORTER_ASSERT(reporter, noPathIter.next(pts) == SkPath::kDone_Verb); in test_iter()
2905 SkPath::Iter iter(p, false); in test_iter()
2906 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kDone_Verb); in test_iter()
2910 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kDone_Verb); in test_iter()
2919 const SkPath::Verb* resultVerbs; in test_iter()
2923 static const SkPath::Verb resultVerbs1[] = { SkPath::kDone_Verb }; in test_iter()
2924 static const SkPath::Verb resultVerbs2[] = { in test_iter()
2925 SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kDone_Verb in test_iter()
2927 static const SkPath::Verb resultVerbs3[] = { in test_iter()
2928SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kClose_Ver… in test_iter()
2930 static const SkPath::Verb resultVerbs4[] = { in test_iter()
2931SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kMove_Verb, SkPath::kClose_Verb, SkPath::kDone_Verb in test_iter()
2933 static const SkPath::Verb resultVerbs5[] = { in test_iter()
2934SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kClose_Verb, SkPath::kMove_Verb, SkPath::kClose_Ve… in test_iter()
2982 } while (gIterTests[i].resultVerbs[j++] != SkPath::kDone_Verb); in test_iter()
3013 REPORTER_ASSERT(reporter, SkPath::kClose_Verb == iter.next(pts, false)); in test_iter()
3020 REPORTER_ASSERT(reporter, SkPath::kQuad_Verb == iter.next(pts, false)); in test_iter()
3023 REPORTER_ASSERT(reporter, SkPath::kDone_Verb == iter.next(pts, true)); in test_iter()
3029 REPORTER_ASSERT(reporter, SkPath::kConic_Verb == iter.next(pts, false)); in test_iter()
3032 REPORTER_ASSERT(reporter, SkPath::kDone_Verb == iter.next(pts, true)); in test_iter()
3038 REPORTER_ASSERT(reporter, SkPath::kCubic_Verb == iter.next(pts, false)); in test_iter()
3041 REPORTER_ASSERT(reporter, SkPath::kDone_Verb == iter.next(pts, true)); in test_iter()
3046 REPORTER_ASSERT(reporter, SkPath::kCubic_Verb == iter.next(pts, false)); in test_iter()
3049 REPORTER_ASSERT(reporter, SkPath::kDone_Verb == iter.next(pts, true)); in test_iter()
3061 REPORTER_ASSERT(reporter, SkPath::kMove_Verb == iter.next(pts)); in test_iter()
3062 REPORTER_ASSERT(reporter, SkPath::kLine_Verb == iter.next(pts)); in test_iter()
3063 REPORTER_ASSERT(reporter, SkPath::kLine_Verb == iter.next(pts)); in test_iter()
3064 REPORTER_ASSERT(reporter, SkPath::kConic_Verb == iter.next(pts)); in test_iter()
3069 SkPath p; in test_raw_iter()
3073 SkPath::RawIter noPathIter; in test_raw_iter()
3074 REPORTER_ASSERT(reporter, noPathIter.next(pts) == SkPath::kDone_Verb); in test_raw_iter()
3077 REPORTER_ASSERT(reporter, noPathIter.next(pts) == SkPath::kDone_Verb); in test_raw_iter()
3080 SkPath::RawIter iter(p); in test_raw_iter()
3081 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kDone_Verb); in test_raw_iter()
3086 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kMove_Verb); in test_raw_iter()
3089 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kDone_Verb); in test_raw_iter()
3095 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kMove_Verb); in test_raw_iter()
3098 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kMove_Verb); in test_raw_iter()
3101 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kMove_Verb); in test_raw_iter()
3104 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kDone_Verb); in test_raw_iter()
3110 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kDone_Verb); in test_raw_iter()
3124 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kMove_Verb); in test_raw_iter()
3127 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kClose_Verb); in test_raw_iter()
3128 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kMove_Verb); in test_raw_iter()
3131 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kClose_Verb); in test_raw_iter()
3132 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kMove_Verb); in test_raw_iter()
3135 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kMove_Verb); in test_raw_iter()
3138 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kClose_Verb); in test_raw_iter()
3139 REPORTER_ASSERT(reporter, iter.next(pts) == SkPath::kDone_Verb); in test_raw_iter()
3152 SkPath::Verb expectedVerbs[22]; // May have leading moveTo in test_raw_iter()
3153 SkPath::Verb nextVerb; in test_raw_iter()
3165 nextVerb = static_cast<SkPath::Verb>((rand.nextU() >> 16) % SkPath::kDone_Verb); in test_raw_iter()
3166 } while (lastWasClose && nextVerb == SkPath::kClose_Verb); in test_raw_iter()
3168 case SkPath::kMove_Verb: in test_raw_iter()
3176 case SkPath::kLine_Verb: in test_raw_iter()
3179 expectedVerbs[numIterVerbs++] = SkPath::kMove_Verb; in test_raw_iter()
3187 case SkPath::kQuad_Verb: in test_raw_iter()
3190 expectedVerbs[numIterVerbs++] = SkPath::kMove_Verb; in test_raw_iter()
3199 case SkPath::kConic_Verb: in test_raw_iter()
3202 expectedVerbs[numIterVerbs++] = SkPath::kMove_Verb; in test_raw_iter()
3212 case SkPath::kCubic_Verb: in test_raw_iter()
3215 expectedVerbs[numIterVerbs++] = SkPath::kMove_Verb; in test_raw_iter()
3226 case SkPath::kClose_Verb: in test_raw_iter()
3245 while ((nextVerb = iter.next(pts)) != SkPath::kDone_Verb) { in test_raw_iter()
3249 case SkPath::kMove_Verb: in test_raw_iter()
3255 case SkPath::kLine_Verb: in test_raw_iter()
3262 case SkPath::kQuad_Verb: in test_raw_iter()
3263 case SkPath::kConic_Verb: in test_raw_iter()
3271 case SkPath::kCubic_Verb: in test_raw_iter()
3280 case SkPath::kClose_Verb: in test_raw_iter()
3293 const SkPath& path, in check_for_circle()
3298 SkPath::Direction isOvalDir; in check_for_circle()
3303 SkPath tmpPath; in check_for_circle()
3311 const SkPath& path, in test_circle_skew()
3313 SkPath tmp; in test_circle_skew()
3329 const SkPath& path, in test_circle_translate()
3331 SkPath tmp; in test_circle_translate()
3349 const SkPath& path, in test_circle_rotate()
3352 SkPath tmp; in test_circle_rotate()
3369 const SkPath& path, in test_circle_mirror_x()
3371 SkPath tmp; in test_circle_mirror_x()
3386 const SkPath& path, in test_circle_mirror_y()
3388 SkPath tmp; in test_circle_mirror_y()
3405 const SkPath& path, in test_circle_mirror_xy()
3407 SkPath tmp; in test_circle_mirror_xy()
3418 SkPath::Direction inDir) { in test_circle_with_direction()
3420 SkPath path; in test_circle_with_direction()
3460 SkPath path; in test_circle_with_add_paths()
3461 SkPath circle; in test_circle_with_add_paths()
3462 SkPath rect; in test_circle_with_add_paths()
3463 SkPath empty; in test_circle_with_add_paths()
3465 const SkPath::Direction kCircleDir = SkPath::kCW_Direction; in test_circle_with_add_paths()
3466 const SkPath::Direction kCircleDirOpposite = SkPath::kCCW_Direction; in test_circle_with_add_paths()
3470 SkIntToScalar(20), SkIntToScalar(20), SkPath::kCW_Direction); in test_circle_with_add_paths()
3496 test_circle_with_direction(reporter, SkPath::kCW_Direction); in test_circle()
3497 test_circle_with_direction(reporter, SkPath::kCCW_Direction); in test_circle()
3500 SkPath path; in test_circle()
3501 path.addCircle(0, 0, SkIntToScalar(10), SkPath::kCW_Direction); in test_circle()
3502 path.addCircle(0, 0, SkIntToScalar(20), SkPath::kCW_Direction); in test_circle()
3507 path.addCircle(0, 0, SkIntToScalar(10), SkPath::kCW_Direction); in test_circle()
3513 path.addCircle(0, 0, SkIntToScalar(10), SkPath::kCW_Direction); in test_circle()
3521 path.addCircle(0, 0, -1, SkPath::kCW_Direction); in test_circle()
3528 SkPath path; in test_oval()
3530 SkPath::Direction dir = SkPath::kCCW_Direction; in test_oval()
3539 SkPath tmp; in test_oval()
3545 REPORTER_ASSERT(reporter, SkPath::kCW_Direction == dir); in test_oval()
3584 REPORTER_ASSERT(reporter, SkPath::kCW_Direction == dir); in test_oval()
3588 static void test_empty(skiatest::Reporter* reporter, const SkPath& p) { in test_empty()
3589 SkPath empty; in test_empty()
3596 REPORTER_ASSERT(reporter, p.getFillType() == SkPath::kWinding_FillType); in test_empty()
3602 static void test_rrect_is_convex(skiatest::Reporter* reporter, SkPath* path, in test_rrect_is_convex()
3603 SkPath::Direction dir) { in test_rrect_is_convex()
3606 path->setConvexity(SkPath::kUnknown_Convexity); in test_rrect_is_convex()
3611 static void test_rrect_convexity_is_unknown(skiatest::Reporter* reporter, SkPath* path, in test_rrect_convexity_is_unknown()
3612 SkPath::Direction dir) { in test_rrect_convexity_is_unknown()
3615 path->setConvexity(SkPath::kUnknown_Convexity); in test_rrect_convexity_is_unknown()
3616 REPORTER_ASSERT(reporter, path->getConvexity() == SkPath::kConvex_Convexity); in test_rrect_convexity_is_unknown()
3621 SkPath p; in test_rrect()
3627 test_rrect_is_convex(reporter, &p, SkPath::kCW_Direction); in test_rrect()
3628 p.addRRect(rr, SkPath::kCCW_Direction); in test_rrect()
3629 test_rrect_is_convex(reporter, &p, SkPath::kCCW_Direction); in test_rrect()
3631 test_rrect_is_convex(reporter, &p, SkPath::kCW_Direction); in test_rrect()
3632 p.addRoundRect(r, &radii[0].fX, SkPath::kCCW_Direction); in test_rrect()
3633 test_rrect_is_convex(reporter, &p, SkPath::kCCW_Direction); in test_rrect()
3635 test_rrect_is_convex(reporter, &p, SkPath::kCW_Direction); in test_rrect()
3636 p.addRoundRect(r, radii[1].fX, radii[1].fY, SkPath::kCCW_Direction); in test_rrect()
3637 test_rrect_is_convex(reporter, &p, SkPath::kCCW_Direction); in test_rrect()
3643 test_rrect_is_convex(reporter, &p, SkPath::kCW_Direction); in test_rrect()
3650 test_rrect_is_convex(reporter, &p, SkPath::kCW_Direction); in test_rrect()
3655 SkPath::Direction dir; in test_rrect()
3658 REPORTER_ASSERT(reporter, SkPath::kCW_Direction == dir); in test_rrect()
3659 test_rrect_is_convex(reporter, &p, SkPath::kCW_Direction); in test_rrect()
3660 p.addRRect(rr, SkPath::kCW_Direction); in test_rrect()
3661 p.addRRect(rr, SkPath::kCW_Direction); in test_rrect()
3664 p.addRRect(rr, SkPath::kCCW_Direction); in test_rrect()
3665 p.addRRect(rr, SkPath::kCCW_Direction); in test_rrect()
3678 test_rrect_convexity_is_unknown(reporter, &p, SkPath::kCW_Direction); in test_rrect()
3687 test_rrect_is_convex(reporter, &p, SkPath::kCW_Direction); in test_rrect()
3691 SkPath p; in test_arc()
3701 SkPath cwOval; in test_arc()
3706 SkPath ccwOval; in test_arc()
3707 ccwOval.addOval(oval, SkPath::kCCW_Direction); in test_arc()
3715 REPORTER_ASSERT(reporter, p.getConvexity() == SkPath::COLINEAR_DIAGONAL_CONVEXITY); in test_arc()
3717 p.setConvexity(SkPath::kUnknown_Convexity); in test_arc()
3718 REPORTER_ASSERT(reporter, p.getConvexity() == SkPath::COLINEAR_DIAGONAL_CONVEXITY); in test_arc()
3747 const SkPath& path) { in check_oval_arc()
3749 SkPath::Direction d = SkPath::kCCW_Direction; in check_oval_arc()
3753 SkPath recreatedPath; in check_oval_arc()
3757 REPORTER_ASSERT(reporter, (SkPath::kCW_Direction == d) == (sweep > 0.f)); in check_oval_arc()
3764 SkPath path; in test_arc_ovals()
3777 SkPath path; in test_arc_ovals()
3785 static void check_move(skiatest::Reporter* reporter, SkPath::RawIter* iter, in check_move()
3788 SkPath::Verb v = iter->next(pts); in check_move()
3789 REPORTER_ASSERT(reporter, v == SkPath::kMove_Verb); in check_move()
3794 static void check_line(skiatest::Reporter* reporter, SkPath::RawIter* iter, in check_line()
3797 SkPath::Verb v = iter->next(pts); in check_line()
3798 REPORTER_ASSERT(reporter, v == SkPath::kLine_Verb); in check_line()
3803 static void check_quad(skiatest::Reporter* reporter, SkPath::RawIter* iter, in check_quad()
3806 SkPath::Verb v = iter->next(pts); in check_quad()
3807 REPORTER_ASSERT(reporter, v == SkPath::kQuad_Verb); in check_quad()
3814 static void check_done(skiatest::Reporter* reporter, SkPath* p, SkPath::RawIter* iter) { in check_done()
3816 SkPath::Verb v = iter->next(pts); in check_done()
3817 REPORTER_ASSERT(reporter, v == SkPath::kDone_Verb); in check_done()
3820 static void check_done_and_reset(skiatest::Reporter* reporter, SkPath* p, SkPath::RawIter* iter) { in check_done_and_reset()
3825 static void check_path_is_move_and_reset(skiatest::Reporter* reporter, SkPath* p, in check_path_is_move_and_reset()
3827 SkPath::RawIter iter(*p); in check_path_is_move_and_reset()
3832 static void check_path_is_line_and_reset(skiatest::Reporter* reporter, SkPath* p, in check_path_is_line_and_reset()
3834 SkPath::RawIter iter(*p); in check_path_is_line_and_reset()
3840 static void check_path_is_line(skiatest::Reporter* reporter, SkPath* p, in check_path_is_line()
3842 SkPath::RawIter iter(*p); in check_path_is_line()
3848 static void check_path_is_line_pair_and_reset(skiatest::Reporter* reporter, SkPath* p, in check_path_is_line_pair_and_reset()
3850 SkPath::RawIter iter(*p); in check_path_is_line_pair_and_reset()
3857 static void check_path_is_quad_and_reset(skiatest::Reporter* reporter, SkPath* p, in check_path_is_quad_and_reset()
3859 SkPath::RawIter iter(*p); in check_path_is_quad_and_reset()
3873 SkPath p; in test_arcTo()
3923 SkPath p, q; in test_addPath()
3941 SkPath p, q; in test_addPathMode()
3950 p.addPath(q, extend ? SkPath::kExtend_AddPathMode : SkPath::kAppend_AddPathMode); in test_addPathMode()
3954 REPORTER_ASSERT(reporter, verbs[0] == SkPath::kMove_Verb); in test_addPathMode()
3955 REPORTER_ASSERT(reporter, verbs[1] == SkPath::kLine_Verb); in test_addPathMode()
3956 REPORTER_ASSERT(reporter, verbs[2] == (extend ? SkPath::kLine_Verb : SkPath::kMove_Verb)); in test_addPathMode()
3957 REPORTER_ASSERT(reporter, verbs[3] == SkPath::kLine_Verb); in test_addPathMode()
3961 SkPath p, q; in test_extendClosedPath()
3968 p.addPath(q, SkPath::kExtend_AddPathMode); in test_extendClosedPath()
3972 REPORTER_ASSERT(reporter, verbs[0] == SkPath::kMove_Verb); in test_extendClosedPath()
3973 REPORTER_ASSERT(reporter, verbs[1] == SkPath::kLine_Verb); in test_extendClosedPath()
3974 REPORTER_ASSERT(reporter, verbs[2] == SkPath::kLine_Verb); in test_extendClosedPath()
3975 REPORTER_ASSERT(reporter, verbs[3] == SkPath::kClose_Verb); in test_extendClosedPath()
3976 REPORTER_ASSERT(reporter, verbs[4] == SkPath::kMove_Verb); in test_extendClosedPath()
3977 REPORTER_ASSERT(reporter, verbs[5] == SkPath::kLine_Verb); in test_extendClosedPath()
3978 REPORTER_ASSERT(reporter, verbs[6] == SkPath::kLine_Verb); in test_extendClosedPath()
3986 static void test_addEmptyPath(skiatest::Reporter* reporter, SkPath::AddPathMode mode) { in test_addEmptyPath()
3987 SkPath p, q, r; in test_addEmptyPath()
4003 SkPath p; in test_conicTo_special_case()
4013 SkPath p; in test_get_point()
4027 SkPath p; in test_contains()
4038 p.setFillType(SkPath::kInverseWinding_FillType); in test_contains()
4040 p.setFillType(SkPath::kWinding_FillType); in test_contains()
4165 p.setFillType(SkPath::kEvenOdd_FillType); in test_contains()
4198 ed.growForRepeatedVerb(SkPath::kMove_Verb, kRepeatCnt); in TestPathRef()
4203 REPORTER_ASSERT(reporter, SkPath::kMove_Verb == pathRef->atVerb(i)); in TestPathRef()
4209 ed.growForRepeatedVerb(SkPath::kLine_Verb, kRepeatCnt); in TestPathRef()
4212 REPORTER_ASSERT(reporter, SkPath::kLine_SegmentMask == pathRef->getSegmentMasks()); in TestPathRef()
4214 REPORTER_ASSERT(reporter, SkPath::kLine_Verb == pathRef->atVerb(i)); in TestPathRef()
4220 ed.growForRepeatedVerb(SkPath::kQuad_Verb, kRepeatCnt); in TestPathRef()
4223 REPORTER_ASSERT(reporter, SkPath::kQuad_SegmentMask == pathRef->getSegmentMasks()); in TestPathRef()
4225 REPORTER_ASSERT(reporter, SkPath::kQuad_Verb == pathRef->atVerb(i)); in TestPathRef()
4232 ed.growForRepeatedVerb(SkPath::kConic_Verb, kRepeatCnt, &weights); in TestPathRef()
4236 REPORTER_ASSERT(reporter, SkPath::kConic_SegmentMask == pathRef->getSegmentMasks()); in TestPathRef()
4239 REPORTER_ASSERT(reporter, SkPath::kConic_Verb == pathRef->atVerb(i)); in TestPathRef()
4245 ed.growForRepeatedVerb(SkPath::kCubic_Verb, kRepeatCnt); in TestPathRef()
4248 REPORTER_ASSERT(reporter, SkPath::kCubic_SegmentMask == pathRef->getSegmentMasks()); in TestPathRef()
4250 REPORTER_ASSERT(reporter, SkPath::kCubic_Verb == pathRef->atVerb(i)); in TestPathRef()
4258 SkPath a; in test_operatorEqual()
4259 SkPath b; in test_operatorEqual()
4262 a.setFillType(SkPath::kInverseWinding_FillType); in test_operatorEqual()
4278 static void compare_dump(skiatest::Reporter* reporter, const SkPath& path, bool force, in compare_dump()
4292 SkPath p; in test_dump()
4306 p.setFillType(SkPath::kEvenOdd_FillType); in test_dump()
4313 p.setFillType(SkPath::kInverseWinding_FillType); in test_dump()
4320 p.setFillType(SkPath::kInverseEvenOdd_FillType); in test_dump()
4327 p.setFillType(SkPath::kWinding_FillType); in test_dump()
4359 static size_t GetFreeSpace(const SkPath& path) { in GetFreeSpace()
4364 SkPath p, q; in TestPathTo()
4382 SkPath p; in TestPathrefListeners()
4416 SkPath q; in TestPathrefListeners()
4427 SkPath path; in test_crbug_629455()
4438 SkPath path; in test_fuzz_crbug_662952()
4458 SkPath path; in test_path_crbugskia6003()
4477 SkPath path; in test_fuzz_crbug_662730()
4487 SkPath path; in test_skbug_6947()
4499 constexpr SkPath::Verb kMove = SkPath::kMove_Verb; in test_skbug_6947()
4500 constexpr SkPath::Verb kLine = SkPath::kLine_Verb; in test_skbug_6947()
4501 constexpr SkPath::Verb kClose = SkPath::kClose_Verb; in test_skbug_6947()
4502 SkPath::Verb verbs[] = {kMove, kLine, kLine, kLine, kLine, kLine, kLine, kLine, kClose, in test_skbug_6947()
4523 SkPath path; in test_skbug_7015()
4524 path.setFillType(SkPath::kWinding_FillType); in test_skbug_7015()
4536 SkPath path; in test_skbug_7051()
4546 SkPath p1, p2, out; in test_interp()
4590 SkPath path; in DEF_TEST()
4623 SkPath p, empty; in DEF_TEST()
4630 SkPath& self = p; in DEF_TEST()
4642 p.getSegmentMasks() & (kCurveSegmentMask | SkPath::kConic_SegmentMask)); in DEF_TEST()
4658 REPORTER_ASSERT(reporter, SkPath::kLine_SegmentMask == p.getSegmentMasks()); in DEF_TEST()
4673 REPORTER_ASSERT(reporter, SkPath::kMove_Verb == verbs[0]); in DEF_TEST()
4674 REPORTER_ASSERT(reporter, SkPath::kLine_Verb == verbs[1]); in DEF_TEST()
4675 REPORTER_ASSERT(reporter, SkPath::kLine_Verb == verbs[2]); in DEF_TEST()
4676 REPORTER_ASSERT(reporter, SkPath::kLine_Verb == verbs[3]); in DEF_TEST()
4677 REPORTER_ASSERT(reporter, SkPath::kClose_Verb == verbs[4]); in DEF_TEST()
4760 test_addEmptyPath(reporter, SkPath::kExtend_AddPathMode); in DEF_TEST()
4761 test_addEmptyPath(reporter, SkPath::kAppend_AddPathMode); in DEF_TEST()
4779 SkPath path; in DEF_TEST()
4794 static void rand_path(SkPath* path, SkRandom& rand, SkPath::Verb verb, int n) { in rand_path()
4797 case SkPath::kLine_Verb: in rand_path()
4800 case SkPath::kQuad_Verb: in rand_path()
4804 case SkPath::kConic_Verb: in rand_path()
4808 case SkPath::kCubic_Verb: in rand_path()
4823 const SkPath::Verb verbs[] = { in DEF_TEST()
4824 SkPath::kLine_Verb, SkPath::kQuad_Verb, SkPath::kConic_Verb, SkPath::kCubic_Verb, in DEF_TEST()
4828 for (SkPath::Verb verb : verbs) { in DEF_TEST()
4829 SkPath path; in DEF_TEST()
4866 SkPath path; in DEF_TEST()
4881 SkPath readBack; in DEF_TEST()
4891 SkPath readBack; in DEF_TEST()
4898 SkPath path; in DEF_TEST()
4903 SkPath::RawIter iter(path); in DEF_TEST()
4905 while (iter.next(pts) != SkPath::kDone_Verb) { in DEF_TEST()
4920 SkPath aPath; in DEF_TEST()
4924 SkPath scalePath = aPath; in DEF_TEST()
4931 SkPath scalePath = aPath; in DEF_TEST()
4981 for (SkPath::FillType ft : {SkPath::kWinding_FillType, SkPath::kInverseWinding_FillType}) { in DEF_TEST()
4991 SkPath path; in DEF_TEST()
5008 auto makePath = [](const SkPoint* points, size_t count, bool close) -> SkPath { in DEF_TEST()
5009 SkPath path; in DEF_TEST()
5018 auto makePath2 = [](const SkPoint* points, const SkPath::Verb* verbs, size_t count) -> SkPath { in DEF_TEST()
5019 SkPath path; in DEF_TEST()
5022 case SkPath::kMove_Verb: in DEF_TEST()
5025 case SkPath::kLine_Verb: in DEF_TEST()
5028 case SkPath::kClose_Verb: in DEF_TEST()
5040 SkPath path = makePath(points, SK_ARRAY_COUNT(points), false); in DEF_TEST()
5056 SkPath::Verb verbs11[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5057 SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kMove_Verb }; in DEF_TEST()
5064 SkPath::Verb verbs14[] = { SkPath::kMove_Verb, SkPath::kMove_Verb, SkPath::kMove_Verb, in DEF_TEST()
5065 SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5066 SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kClose_Verb, in DEF_TEST()
5067 SkPath::kLine_Verb, SkPath::kClose_Verb }; in DEF_TEST()
5073 SkPath::Verb verbs15[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5074 SkPath::kLine_Verb, SkPath::kMove_Verb }; in DEF_TEST()
5085 SkPath::Verb verbs19[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5086 SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5087 SkPath::kLine_Verb, SkPath::kClose_Verb, SkPath::kMove_Verb, in DEF_TEST()
5088 SkPath::kLine_Verb, SkPath::kLine_Verb }; in DEF_TEST()
5094 SkPath::Verb verbs23[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kMove_Verb, in DEF_TEST()
5095 SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5096 SkPath::kLine_Verb, SkPath::kClose_Verb }; in DEF_TEST()
5104 SkPath::Verb verbs29[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5105 SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kMove_Verb, in DEF_TEST()
5106 SkPath::kClose_Verb }; in DEF_TEST()
5111 SkPath::Verb verbs31[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5112 SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kMove_Verb, in DEF_TEST()
5113 SkPath::kClose_Verb }; in DEF_TEST()
5120 SkPath::Verb verbs36[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5121 SkPath::kLine_Verb, SkPath::kMove_Verb, SkPath::kLine_Verb }; in DEF_TEST()
5126 SkPath::Verb verbs39[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5127 SkPath::kLine_Verb }; in DEF_TEST()
5132 SkPath::Verb verbsAA[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5133 SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5134 SkPath::kLine_Verb, SkPath::kClose_Verb }; in DEF_TEST()
5142 SkPath::Verb verbs41[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5143 SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kMove_Verb, in DEF_TEST()
5144 SkPath::kClose_Verb }; in DEF_TEST()
5151 SkPath::Verb verbs53[] = { SkPath::kMove_Verb, SkPath::kLine_Verb, SkPath::kLine_Verb, in DEF_TEST()
5152 SkPath::kLine_Verb, SkPath::kLine_Verb, SkPath::kMove_Verb, in DEF_TEST()
5153 SkPath::kClose_Verb }; in DEF_TEST()
5174 SkPath path; in DEF_TEST()
5189 SkPath path; in draw_triangle()
5226 static void add_verbs(SkPath* path, int count) { in add_verbs()
5243 SkPath unique_path, shared_path; in DEF_TEST()
5247 const SkPath copy = shared_path; in DEF_TEST()
5275 SkPath p; in DEF_TEST()
5289 SkPath path; in DEF_TEST()
5294 SkPath shallowPath = path; in DEF_TEST()
5320 static bool conditional_convex(const SkPath& path, bool is_convex) { in conditional_convex()
5321 SkPath::Convexity c = path.getConvexityOrUnknown(); in conditional_convex()
5322 return is_convex ? (c == SkPath::kConvex_Convexity) : (c != SkPath::kConvex_Convexity); in conditional_convex()
5327 void survive(SkPath* path, const Xforms& x, bool isAxisAligned, skiatest::Reporter* reporter, in survive()
5331 REPORTER_ASSERT(reporter, path->getConvexity() == SkPath::kConvex_Convexity); in survive()
5333 SkPath path2; in survive()
5338 REPORTER_ASSERT(reporter, path2.getConvexityOrUnknown() == SkPath::kConvex_Convexity); in survive()
5344 REPORTER_ASSERT(reporter, path2.getConvexityOrUnknown() == SkPath::kConvex_Convexity); in survive()
5346 REPORTER_ASSERT(reporter, path->getConvexityOrUnknown() == SkPath::kConvex_Convexity); in survive()
5373 REPORTER_ASSERT(reporter, path2.getConvexityOrUnknown() != SkPath::kConvex_Convexity); in survive()
5374 REPORTER_ASSERT(reporter, path->getConvexityOrUnknown() != SkPath::kConvex_Convexity); in survive()
5380 SkPath path; in DEF_TEST()
5382 survive(&path, x, true, r, [](const SkPath& p) { return p.isRect(nullptr); }); in DEF_TEST()
5386 survive(&path, x, true, r, [](const SkPath& p) { return p.isOval(nullptr); }); in DEF_TEST()
5390 survive(&path, x, true, r, [](const SkPath& p) { return p.isRRect(nullptr); }); in DEF_TEST()
5395 REPORTER_ASSERT(r, path.getConvexity() == SkPath::kConvex_Convexity); in DEF_TEST()
5396 survive(&path, x, false, r, [](const SkPath& p) { return true; }); in DEF_TEST()
5411 SkPath copyPath; in DEF_TEST()
5412 SkFont().getPaths(glyphs, len, [](const SkPath* src, const SkMatrix& mx, void* ctx) { in DEF_TEST()
5414 ((SkPath*)ctx)->addPath(*src, mx); in DEF_TEST()
5419 SkPath path; in DEF_TEST()