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

Unified Diff: bench/SkBenchmark.cpp

Issue 16069010: extend SkBenchmark to allow a bench to return a durationScale, which allows it to perform fewer act… (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years, 7 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/SkBenchmark.h ('k') | bench/benchmain.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bench/SkBenchmark.cpp
diff --git a/bench/SkBenchmark.cpp b/bench/SkBenchmark.cpp
index 6afcd8e9f39e9db09792d148f2c92c6652e6b528..43f78b0f2ddc50eb15d8ebddd617e1fdfd9b319b 100644
--- a/bench/SkBenchmark.cpp
+++ b/bench/SkBenchmark.cpp
@@ -20,6 +20,7 @@ SkBenchmark::SkBenchmark(void* defineDict) {
fDither = SkTriState::kDefault;
fHasStrokeWidth = false;
fIsRendering = true;
+ fOrMask = fClearMask = 0;
}
const char* SkBenchmark::getName() {
@@ -47,6 +48,8 @@ void SkBenchmark::setupPaint(SkPaint* paint) {
paint->setAntiAlias(fForceAA);
paint->setFilterBitmap(fForceFilter);
+ paint->setFlags((paint->getFlags() & ~fClearMask) | fOrMask);
+
if (SkTriState::kDefault != fDither) {
paint->setDither(SkTriState::kTrue == fDither);
}
« no previous file with comments | « bench/SkBenchmark.h ('k') | bench/benchmain.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698