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

Unified Diff: samplecode/SampleText.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 | « samplecode/SampleStrokePath.cpp ('k') | samplecode/SampleTextAlpha.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: samplecode/SampleText.cpp
diff --git a/samplecode/SampleText.cpp b/samplecode/SampleText.cpp
index b4091ff328efc50d6a35a2254b76bf0ffb92ad3a..c6aaa52a0b11f76e3823104be4b9e26406b7972f 100644
--- a/samplecode/SampleText.cpp
+++ b/samplecode/SampleText.cpp
@@ -135,7 +135,7 @@ static void test_breakText() {
SkASSERT(mm == width);
}
-static SkMWCRandom gRand;
+static SkRandom gRand;
class SkPowerMode : public SkXfermode {
public:
@@ -287,7 +287,7 @@ protected:
canvas.drawText(s, strlen(s), SkIntToScalar(8), SkIntToScalar(14), paint);
}
- static void fill_pts(SkPoint pts[], size_t n, SkMWCRandom* rand) {
+ static void fill_pts(SkPoint pts[], size_t n, SkRandom* rand) {
for (size_t i = 0; i < n; i++)
pts[i].set(rand->nextUScalar1() * 640, rand->nextUScalar1() * 480);
}
« no previous file with comments | « samplecode/SampleStrokePath.cpp ('k') | samplecode/SampleTextAlpha.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698