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

Unified Diff: bench/PMFloatBench.cpp

Issue 977773002: Update SkPMFloat API a bit. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 32 Created 5 years, 10 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 | « no previous file | src/core/SkPMFloat.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bench/PMFloatBench.cpp
diff --git a/bench/PMFloatBench.cpp b/bench/PMFloatBench.cpp
index 1f9c291cde1b3b414b98805ea5ed1cb711e6cd96..ee4914a45b018b8e29b064088a588500c912e5d9 100644
--- a/bench/PMFloatBench.cpp
+++ b/bench/PMFloatBench.cpp
@@ -30,8 +30,7 @@ struct PMFloatBench : public Benchmark {
// But it's a lot faster not to, and this code won't really mind the non-PM colors.
SkPMColor c = lcg_rand(&seed);
#endif
- SkPMFloat pmf;
- pmf.set(c);
+ SkPMFloat pmf = SkPMFloat::FromPMColor(c);
SkPMColor back = fClamp ? pmf.clamped() : pmf.get();
junk ^= back;
}
« no previous file with comments | « no previous file | src/core/SkPMFloat.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698