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

Unified Diff: bench/PathBench.cpp

Issue 1379923005: Remove const from `const int loops`. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: n too Created 5 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 | « bench/PatchGridBench.cpp ('k') | bench/PathIterBench.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bench/PathBench.cpp
diff --git a/bench/PathBench.cpp b/bench/PathBench.cpp
index e09fc3ecab2b8f51acb687acdaa421c4e01cb82a..d0ede02ab70b5bd31531eb0dc4326bb22a22c92e 100644
--- a/bench/PathBench.cpp
+++ b/bench/PathBench.cpp
@@ -51,7 +51,7 @@ protected:
return fName.c_str();
}
- void onDraw(const int loops, SkCanvas* canvas) override {
+ void onDraw(int loops, SkCanvas* canvas) override {
SkPaint paint(fPaint);
this->setupPaint(&paint);
@@ -329,7 +329,7 @@ protected:
this->createData(10, 100);
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
for (int i = 0; i < loops; ++i) {
if (i % 1000 == 0) {
fPath.reset(); // PathRef memory can grow without bound otherwise.
@@ -363,7 +363,7 @@ protected:
}
this->finishedMakingPaths();
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
for (int i = 0; i < loops; ++i) {
int idx = i & (kPathCnt - 1);
fCopies[idx] = fPaths[idx];
@@ -403,7 +403,7 @@ protected:
}
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
if (fInPlace) {
for (int i = 0; i < loops; ++i) {
fPaths[i & (kPathCnt - 1)].transform(fMatrix);
@@ -450,7 +450,7 @@ protected:
this->finishedMakingPaths();
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
for (int i = 0; i < loops; ++i) {
int idx = i & (kPathCnt - 1);
fParity ^= (fPaths[idx] == fCopies[idx & ~0x1]);
@@ -514,7 +514,7 @@ protected:
this->finishedMakingPaths();
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
switch (fType) {
case kAdd_AddType:
for (int i = 0; i < loops; ++i) {
@@ -582,7 +582,7 @@ protected:
return fName.c_str();
}
- void onDraw(const int loops, SkCanvas* canvas) override {
+ void onDraw(int loops, SkCanvas* canvas) override {
SkPaint paint;
paint.setColor(SK_ColorBLACK);
@@ -688,7 +688,7 @@ protected:
SkASSERT(path->isConvex());
}
- void onDraw(const int loops, SkCanvas* canvas) override {
+ void onDraw(int loops, SkCanvas* canvas) override {
SkRandom rand;
SkRect r;
@@ -762,7 +762,7 @@ private:
return fName.c_str();
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
for (int i = 0; i < loops; ++i) {
const SkRect& rect = fQueryRects[i % kQueryRectCnt];
fParity = fParity != fPath.conservativelyContainsRect(rect);
@@ -825,7 +825,7 @@ public:
private:
const char* onGetName() override { return fName.c_str(); }
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
for (int i = 0; i < loops; ++i) {
fRQ.chop(fDst);
}
@@ -841,7 +841,7 @@ public:
ConicBench_EvalPos(bool useV2) : fUseV2(useV2) {
fName.printf("conic-eval-pos%d", useV2);
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
if (fUseV2) {
for (int i = 0; i < loops; ++i) {
for (int j = 0; j < 1000; ++j) {
@@ -866,7 +866,7 @@ public:
ConicBench_EvalTan(bool useV2) : fUseV2(useV2) {
fName.printf("conic-eval-tan%d", useV2);
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
if (fUseV2) {
for (int i = 0; i < loops; ++i) {
for (int j = 0; j < 1000; ++j) {
@@ -930,7 +930,7 @@ protected:
return "conic-compute-error";
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
SkVector err;
for (int i = 0; i < loops; ++i) {
for (int j = 0; j < CONICS; ++j) {
@@ -952,7 +952,7 @@ protected:
return "conic-asQuadTol";
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
for (int i = 0; i < loops; ++i) {
for (int j = 0; j < CONICS; ++j) {
fConics[j].asQuadTol(SK_ScalarHalf);
@@ -973,7 +973,7 @@ protected:
return "conic-quadPow2";
}
- void onDraw(const int loops, SkCanvas*) override {
+ void onDraw(int loops, SkCanvas*) override {
for (int i = 0; i < loops; ++i) {
for (int j = 0; j < CONICS; ++j) {
fConics[j].computeQuadPOW2(SK_ScalarHalf);
« no previous file with comments | « bench/PatchGridBench.cpp ('k') | bench/PathIterBench.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698