Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1221)

Unified Diff: gm/mixedxfermodes.cpp

Issue 23576015: Change old PRG to be SkLCGRandom; change new one to SkRandom (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Fix some spurious SkMWCRandoms Created 7 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « gm/linepaths.cpp ('k') | gm/nested.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: gm/mixedxfermodes.cpp
diff --git a/gm/mixedxfermodes.cpp b/gm/mixedxfermodes.cpp
index 645143a45304443e4519e133cb1d61fab5f454c9..e3ce91a9dcb0b210a006651449b0f15a8bfca3fc 100644
--- a/gm/mixedxfermodes.cpp
+++ b/gm/mixedxfermodes.cpp
@@ -32,7 +32,7 @@ protected:
void drawShape(SkCanvas* canvas,
const SkPaint& paint,
- SkMWCRandom* random) {
+ SkRandom* random) {
static const SkRect kRect = SkRect::MakeXYWH(SkIntToScalar(-50), SkIntToScalar(-50),
SkIntToScalar(75), SkIntToScalar(105));
int shape = random->nextULessThan(5);
@@ -102,7 +102,7 @@ protected:
canvas->drawPaint(bgPaint);
SkISize size = canvas->getDeviceSize();
SkScalar maxScale = SkScalarSqrt((SkIntToScalar(size.fWidth * size.fHeight))) / 300;
- SkMWCRandom random;
+ SkRandom random;
for (int i = 0; i < kNumShapes; ++i) {
SkScalar s = random.nextRangeScalar(SK_Scalar1 / 8, SK_Scalar1) * maxScale;
SkScalar r = random.nextRangeScalar(0, SkIntToScalar(360));
« no previous file with comments | « gm/linepaths.cpp ('k') | gm/nested.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698