Lines Matching refs:rand
18 static void rnd_quad(SkPath* p, SkPaint* paint, SkRandom& rand) { in rnd_quad() argument
19 auto a = rand.nextRangeScalar(0,W), in rnd_quad()
20 b = rand.nextRangeScalar(0,H); in rnd_quad()
23 auto c = rand.nextRangeScalar(W/4, W), in rnd_quad()
24 d = rand.nextRangeScalar( 0, H), in rnd_quad()
25 e = rand.nextRangeScalar( 0, W), in rnd_quad()
26 f = rand.nextRangeScalar(H/4, H); in rnd_quad()
29 paint->setColor(rand.nextU()); in rnd_quad()
30 SkScalar width = rand.nextRangeScalar(1, 5); in rnd_quad()
36 static void rnd_cubic(SkPath* p, SkPaint* paint, SkRandom& rand) { in rnd_cubic() argument
37 auto a = rand.nextRangeScalar(0,W), in rnd_cubic()
38 b = rand.nextRangeScalar(0,H); in rnd_cubic()
41 auto c = rand.nextRangeScalar(W/4, W), in rnd_cubic()
42 d = rand.nextRangeScalar( 0, H), in rnd_cubic()
43 e = rand.nextRangeScalar( 0, W), in rnd_cubic()
44 f = rand.nextRangeScalar(H/4, H), in rnd_cubic()
45 g = rand.nextRangeScalar(W/4, W), in rnd_cubic()
46 h = rand.nextRangeScalar(H/4, H); in rnd_cubic()
49 paint->setColor(rand.nextU()); in rnd_cubic()
50 SkScalar width = rand.nextRangeScalar(1, 5); in rnd_cubic()
76 SkRandom rand; in onDraw() local
79 rnd_quad(&p, &paint, rand); in onDraw()
85 rnd_cubic(&p, &paint, rand); in onDraw()