Lines Matching refs:SkRRect
17 SkRRect rr, rr2; in test_inset()
41 SkRRect empty; in test_round_rect_basic()
45 REPORTER_ASSERT(reporter, SkRRect::kEmpty_Type == empty.type()); in test_round_rect_basic()
49 REPORTER_ASSERT(reporter, zeroPt == empty.radii((SkRRect::Corner) i)); in test_round_rect_basic()
55 SkRRect rr1; in test_round_rect_basic()
58 REPORTER_ASSERT(reporter, SkRRect::kRect_Type == rr1.type()); in test_round_rect_basic()
62 REPORTER_ASSERT(reporter, zeroPt == rr1.radii((SkRRect::Corner) i)); in test_round_rect_basic()
67 SkRRect rr2; in test_round_rect_basic()
70 REPORTER_ASSERT(reporter, SkRRect::kOval_Type == rr2.type()); in test_round_rect_basic()
75 rr2.radii((SkRRect::Corner) i).equalsWithinTolerance(halfPoint)); in test_round_rect_basic()
80 SkRRect rr3; in test_round_rect_basic()
83 REPORTER_ASSERT(reporter, SkRRect::kSimple_Type == rr3.type()); in test_round_rect_basic()
87 REPORTER_ASSERT(reporter, p == rr3.radii((SkRRect::Corner) i)); in test_round_rect_basic()
93 SkRRect rr4; in test_round_rect_basic()
96 REPORTER_ASSERT(reporter, SkRRect::kSimple_Type == rr4.type()); in test_round_rect_basic()
100 REPORTER_ASSERT(reporter, radii[i] == rr4.radii((SkRRect::Corner) i)); in test_round_rect_basic()
106 SkRRect rr5; in test_round_rect_basic()
109 REPORTER_ASSERT(reporter, SkRRect::kComplex_Type == rr5.type()); in test_round_rect_basic()
113 REPORTER_ASSERT(reporter, radii2[i] == rr5.radii((SkRRect::Corner) i)); in test_round_rect_basic()
127 SkRRect empty; in test_round_rect_rects()
131 REPORTER_ASSERT(reporter, SkRRect::kEmpty_Type == empty.type()); in test_round_rect_rects()
137 SkRRect rr1; in test_round_rect_rects()
140 REPORTER_ASSERT(reporter, SkRRect::kRect_Type == rr1.type()); in test_round_rect_rects()
147 SkRRect rr2; in test_round_rect_rects()
150 REPORTER_ASSERT(reporter, SkRRect::kRect_Type == rr2.type()); in test_round_rect_rects()
157 SkRRect rr3; in test_round_rect_rects()
159 REPORTER_ASSERT(reporter, SkRRect::kComplex_Type == rr3.type()); in test_round_rect_rects()
167 SkRRect rr1; in test_round_rect_ovals()
170 REPORTER_ASSERT(reporter, SkRRect::kOval_Type == rr1.type()); in test_round_rect_ovals()
179 SkRRect rr1; in test_round_rect_general()
182 REPORTER_ASSERT(reporter, SkRRect::kSimple_Type == rr1.type()); in test_round_rect_general()
187 SkRRect rr2; in test_round_rect_general()
190 REPORTER_ASSERT(reporter, SkRRect::kComplex_Type == rr2.type()); in test_round_rect_general()
201 SkRRect rr1; in test_round_rect_iffy_parameters()
204 REPORTER_ASSERT(reporter, SkRRect::kComplex_Type == rr1.type()); in test_round_rect_iffy_parameters()
206 const SkPoint& p = rr1.radii(SkRRect::kUpperLeft_Corner); in test_round_rect_iffy_parameters()
212 SkRRect rr2; in test_round_rect_iffy_parameters()
215 REPORTER_ASSERT(reporter, SkRRect::kRect_Type == rr2.type()); in test_round_rect_iffy_parameters()
217 const SkPoint& p2 = rr2.radii(SkRRect::kUpperLeft_Corner); in test_round_rect_iffy_parameters()
225 static void test_direction(skiatest::Reporter* reporter, const SkRRect &rr, in test_direction()
253 SkRRect rrects[kNumRRects]; in test_round_rect_contains_rect()
358 static void assert_transform_failure(skiatest::Reporter* reporter, const SkRRect& orig, in assert_transform_failure()
362 SkRRect dst; in assert_transform_failure()
365 const SkRRect copyOfDst = dst; in assert_transform_failure()
366 const SkRRect copyOfOrig = orig; in assert_transform_failure()
378 const SkVector& origUL = orig.radii(SkRRect::kUpperLeft_Corner); \
379 const SkVector& origUR = orig.radii(SkRRect::kUpperRight_Corner); \
380 const SkVector& origLR = orig.radii(SkRRect::kLowerRight_Corner); \
381 const SkVector& origLL = orig.radii(SkRRect::kLowerLeft_Corner); \
382 const SkVector& dstUL = dst.radii(SkRRect::kUpperLeft_Corner); \
383 const SkVector& dstUR = dst.radii(SkRRect::kUpperRight_Corner); \
384 const SkVector& dstLR = dst.radii(SkRRect::kLowerRight_Corner); \
385 const SkVector& dstLL = dst.radii(SkRRect::kLowerLeft_Corner)
388 static void test_transform_helper(skiatest::Reporter* reporter, const SkRRect& orig) { in test_transform_helper()
389 SkRRect dst; in test_transform_helper()
433 orig.radii((SkRRect::Corner) i) == dst.radii((SkRRect::Corner) i)); in test_transform_helper()
523 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst.radii((SkRRect::Corner) i).fX, in test_transform_helper()
524 SkScalarMul(orig.radii((SkRRect::Corner) i).fX, xScale))); in test_transform_helper()
525 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst.radii((SkRRect::Corner) i).fY, in test_transform_helper()
526 SkScalarMul(orig.radii((SkRRect::Corner) i).fY, yScale))); in test_transform_helper()
539 SkRRect rrect; in test_round_rect_transform()