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

Side by Side Diff: bench/AAClipBench.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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | bench/BicubicBench.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkBenchmark.h" 8 #include "SkBenchmark.h"
9 #include "SkAAClip.h" 9 #include "SkAAClip.h"
10 #include "SkPath.h" 10 #include "SkPath.h"
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 typedef SkBenchmark INHERITED; 87 typedef SkBenchmark INHERITED;
88 }; 88 };
89 89
90 //////////////////////////////////////////////////////////////////////////////// 90 ////////////////////////////////////////////////////////////////////////////////
91 // This bench tests out nested clip stacks. It is intended to simulate 91 // This bench tests out nested clip stacks. It is intended to simulate
92 // how WebKit nests clips. 92 // how WebKit nests clips.
93 class NestedAAClipBench : public SkBenchmark { 93 class NestedAAClipBench : public SkBenchmark {
94 SkString fName; 94 SkString fName;
95 bool fDoAA; 95 bool fDoAA;
96 SkRect fDrawRect; 96 SkRect fDrawRect;
97 SkMWCRandom fRandom; 97 SkRandom fRandom;
98 98
99 static const int kNumDraws = SkBENCHLOOP(2); 99 static const int kNumDraws = SkBENCHLOOP(2);
100 static const int kNestingDepth = 3; 100 static const int kNestingDepth = 3;
101 static const int kImageSize = 400; 101 static const int kImageSize = 400;
102 102
103 SkPoint fSizes[kNestingDepth+1]; 103 SkPoint fSizes[kNestingDepth+1];
104 104
105 public: 105 public:
106 NestedAAClipBench(void* param, bool doAA) 106 NestedAAClipBench(void* param, bool doAA)
107 : INHERITED(param) 107 : INHERITED(param)
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
281 static BenchRegistry gReg000(Fact000); 281 static BenchRegistry gReg000(Fact000);
282 static BenchRegistry gReg001(Fact001); 282 static BenchRegistry gReg001(Fact001);
283 static BenchRegistry gReg002(Fact002); 283 static BenchRegistry gReg002(Fact002);
284 static BenchRegistry gReg003(Fact003); 284 static BenchRegistry gReg003(Fact003);
285 285
286 static SkBenchmark* Fact004(void* p) { return SkNEW_ARGS(NestedAAClipBench, (p, false)); } 286 static SkBenchmark* Fact004(void* p) { return SkNEW_ARGS(NestedAAClipBench, (p, false)); }
287 static SkBenchmark* Fact005(void* p) { return SkNEW_ARGS(NestedAAClipBench, (p, true)); } 287 static SkBenchmark* Fact005(void* p) { return SkNEW_ARGS(NestedAAClipBench, (p, true)); }
288 288
289 static BenchRegistry gReg004(Fact004); 289 static BenchRegistry gReg004(Fact004);
290 static BenchRegistry gReg005(Fact005); 290 static BenchRegistry gReg005(Fact005);
OLDNEW
« no previous file with comments | « no previous file | bench/BicubicBench.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698