Lines Matching refs:SkRRect

15         SkRRect rr;  in test_tricky_radii()
28 SkRRect rr; in test_tricky_radii()
31 REPORTER_ASSERT(reporter, (double) rr.radii(SkRRect::kUpperRight_Corner).fY + in test_tricky_radii()
32 (double) rr.radii(SkRRect::kLowerRight_Corner).fY <= in test_tricky_radii()
38 SkRRect rr; in test_empty_crbug_458524()
43 SkRRect other; in test_empty_crbug_458524()
47 REPORTER_ASSERT(reporter, SkRRect::kEmpty_Type == other.getType()); in test_empty_crbug_458524()
68 SkRRect r; in test_empty()
109 SkRRect rr, rr2; in test_inset()
134 SkRRect rr; in test_9patch_rrect()
137 REPORTER_ASSERT(reporter, SkRRect::kNinePatch_Type == rr.type()); in test_9patch_rrect()
146 REPORTER_ASSERT(reporter, rquad[i] == rr.radii((SkRRect::Corner) i)); in test_9patch_rrect()
149 SkRRect rr2; // construct the same RR using the most general set function in test_9patch_rrect()
159 SkRRect empty; in test_round_rect_basic()
163 REPORTER_ASSERT(reporter, SkRRect::kEmpty_Type == empty.type()); in test_round_rect_basic()
167 REPORTER_ASSERT(reporter, zeroPt == empty.radii((SkRRect::Corner) i)); in test_round_rect_basic()
173 SkRRect rr1; in test_round_rect_basic()
176 REPORTER_ASSERT(reporter, SkRRect::kRect_Type == rr1.type()); in test_round_rect_basic()
180 REPORTER_ASSERT(reporter, zeroPt == rr1.radii((SkRRect::Corner) i)); in test_round_rect_basic()
182 SkRRect rr1_2; // construct the same RR using the most general set function in test_round_rect_basic()
186 SkRRect rr1_3; // construct the same RR using the nine patch set function in test_round_rect_basic()
192 SkRRect rr2; in test_round_rect_basic()
195 REPORTER_ASSERT(reporter, SkRRect::kOval_Type == rr2.type()); in test_round_rect_basic()
200 rr2.radii((SkRRect::Corner) i).equalsWithinTolerance(halfPoint)); in test_round_rect_basic()
202 SkRRect rr2_2; // construct the same RR using the most general set function in test_round_rect_basic()
207 SkRRect rr2_3; // construct the same RR using the nine patch set function in test_round_rect_basic()
213 SkRRect rr3; in test_round_rect_basic()
216 REPORTER_ASSERT(reporter, SkRRect::kSimple_Type == rr3.type()); in test_round_rect_basic()
220 REPORTER_ASSERT(reporter, p == rr3.radii((SkRRect::Corner) i)); in test_round_rect_basic()
222 SkRRect rr3_2; // construct the same RR using the most general set function in test_round_rect_basic()
226 SkRRect rr3_3; // construct the same RR using the nine patch set function in test_round_rect_basic()
246 SkRRect rr5; in test_round_rect_basic()
249 REPORTER_ASSERT(reporter, SkRRect::kComplex_Type == rr5.type()); in test_round_rect_basic()
253 REPORTER_ASSERT(reporter, radii2[i] == rr5.radii((SkRRect::Corner) i)); in test_round_rect_basic()
266 SkRRect empty; in test_round_rect_rects()
270 REPORTER_ASSERT(reporter, SkRRect::kEmpty_Type == empty.type()); in test_round_rect_rects()
276 SkRRect rr1; in test_round_rect_rects()
279 REPORTER_ASSERT(reporter, SkRRect::kRect_Type == rr1.type()); in test_round_rect_rects()
286 SkRRect rr2; in test_round_rect_rects()
289 REPORTER_ASSERT(reporter, SkRRect::kRect_Type == rr2.type()); in test_round_rect_rects()
296 SkRRect rr3; in test_round_rect_rects()
298 REPORTER_ASSERT(reporter, SkRRect::kComplex_Type == rr3.type()); in test_round_rect_rects()
306 SkRRect rr1; in test_round_rect_ovals()
309 REPORTER_ASSERT(reporter, SkRRect::kOval_Type == rr1.type()); in test_round_rect_ovals()
318 SkRRect rr1; in test_round_rect_general()
321 REPORTER_ASSERT(reporter, SkRRect::kSimple_Type == rr1.type()); in test_round_rect_general()
326 SkRRect rr2; in test_round_rect_general()
329 REPORTER_ASSERT(reporter, SkRRect::kComplex_Type == rr2.type()); in test_round_rect_general()
340 SkRRect rr1; in test_round_rect_iffy_parameters()
343 REPORTER_ASSERT(reporter, SkRRect::kComplex_Type == rr1.type()); in test_round_rect_iffy_parameters()
345 const SkPoint& p = rr1.radii(SkRRect::kUpperLeft_Corner); in test_round_rect_iffy_parameters()
351 SkRRect rr2; in test_round_rect_iffy_parameters()
354 REPORTER_ASSERT(reporter, SkRRect::kRect_Type == rr2.type()); in test_round_rect_iffy_parameters()
356 const SkPoint& p2 = rr2.radii(SkRRect::kUpperLeft_Corner); in test_round_rect_iffy_parameters()
364 static void test_direction(skiatest::Reporter* reporter, const SkRRect &rr, in test_direction()
392 SkRRect rrects[kNumRRects]; in test_round_rect_contains_rect()
497 static void assert_transform_failure(skiatest::Reporter* reporter, const SkRRect& orig, in assert_transform_failure()
501 SkRRect dst; in assert_transform_failure()
504 const SkRRect copyOfDst = dst; in assert_transform_failure()
505 const SkRRect copyOfOrig = orig; in assert_transform_failure()
517 const SkVector& origUL = orig.radii(SkRRect::kUpperLeft_Corner); \
518 const SkVector& origUR = orig.radii(SkRRect::kUpperRight_Corner); \
519 const SkVector& origLR = orig.radii(SkRRect::kLowerRight_Corner); \
520 const SkVector& origLL = orig.radii(SkRRect::kLowerLeft_Corner); \
521 const SkVector& dstUL = dst.radii(SkRRect::kUpperLeft_Corner); \
522 const SkVector& dstUR = dst.radii(SkRRect::kUpperRight_Corner); \
523 const SkVector& dstLR = dst.radii(SkRRect::kLowerRight_Corner); \
524 const SkVector& dstLL = dst.radii(SkRRect::kLowerLeft_Corner)
527 static void test_transform_helper(skiatest::Reporter* reporter, const SkRRect& orig) { in test_transform_helper()
528 SkRRect dst; in test_transform_helper()
572 orig.radii((SkRRect::Corner) i) == dst.radii((SkRRect::Corner) i)); in test_transform_helper()
662 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst.radii((SkRRect::Corner) i).fX, in test_transform_helper()
663 SkScalarMul(orig.radii((SkRRect::Corner) i).fX, xScale))); in test_transform_helper()
664 REPORTER_ASSERT(reporter, SkScalarNearlyEqual(dst.radii((SkRRect::Corner) i).fY, in test_transform_helper()
665 SkScalarMul(orig.radii((SkRRect::Corner) i).fY, yScale))); in test_transform_helper()
678 SkRRect rrect; in test_round_rect_transform()
701 SkRRect rrect; in test_issue_2696()
709 SkRRect dst; in test_issue_2696()
719 SkScalarNearlyEqual(dst.radii((SkRRect::Corner)i).fX, halfWidth)); in test_issue_2696()
721 SkScalarNearlyEqual(dst.radii((SkRRect::Corner)i).fY, halfHeight)); in test_issue_2696()