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

Unified Diff: bench/PathBench.cpp

Issue 73643005: Implement a benchmark for GrResourceCache (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years, 1 month 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
Index: bench/PathBench.cpp
diff --git a/bench/PathBench.cpp b/bench/PathBench.cpp
index 11151d9d45329e4bdfcbb40cbb49997ec85dbf7e..ab68c092301b3c5037a4173b54024a7ce32c4915 100644
--- a/bench/PathBench.cpp
+++ b/bench/PathBench.cpp
@@ -217,7 +217,10 @@ private:
class RandomPathBench : public SkBenchmark {
public:
RandomPathBench() {
- fIsRendering = false;
+ }
+
+ virtual bool isSuitableFor(Backend backend) SK_OVERRIDE {
+ return backend == kNonRendering_Backend;
}
protected:
@@ -761,7 +764,6 @@ public:
};
ConservativelyContainsBench(Type type) {
- fIsRendering = false;
fParity = false;
fName = "conservatively_contains_";
switch (type) {
@@ -780,6 +782,10 @@ public:
}
}
+ virtual bool isSuitableFor(Backend backend) SK_OVERRIDE {
+ return backend == kNonRendering_Backend;
+ }
+
private:
virtual const char* onGetName() SK_OVERRIDE {
return fName.c_str();
@@ -903,7 +909,10 @@ public:
for (int i = 0; i < CONICS; ++i) {
rand_conic(&fConics[i], rand);
}
- fIsRendering = false;
+ }
+
+ virtual bool isSuitableFor(Backend backend) SK_OVERRIDE {
+ return backend == kNonRendering_Backend;
}
protected:

Powered by Google App Engine
This is Rietveld 408576698