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

Unified Diff: src/core/SkGlyphCache.h

Issue 1866293003: Decouple contrast boost from fake gamma. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 8 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
Index: src/core/SkGlyphCache.h
diff --git a/src/core/SkGlyphCache.h b/src/core/SkGlyphCache.h
index 2b5262ba5eb914446d507dff99b7636eeb5450ec..33b03fa0288d67d75ec5337b34ceb95d19069826 100644
--- a/src/core/SkGlyphCache.h
+++ b/src/core/SkGlyphCache.h
@@ -285,13 +285,14 @@ public:
SkAutoGlyphCache(const SkPaint& paint,
const SkSurfaceProps* surfaceProps,
const SkMatrix* matrix)
- : INHERITED(paint.detachCache(surfaceProps, SkPaint::FakeGamma::On, matrix))
+ : INHERITED(paint.detachCache(surfaceProps, SkPaint::kFakeGammaAndContrast_FontWeightFlag,
+ matrix))
{}
SkAutoGlyphCache(const SkPaint& paint,
const SkSurfaceProps* surfaceProps,
- SkPaint::FakeGamma fakeGamma,
+ uint32_t fontWeightFlags,
const SkMatrix* matrix)
- : INHERITED(paint.detachCache(surfaceProps, fakeGamma, matrix))
+ : INHERITED(paint.detachCache(surfaceProps, fontWeightFlags, matrix))
{}
private:
using INHERITED = std::unique_ptr<SkGlyphCache, SkGlyphCache::AttachCacheFunctor>;
@@ -302,7 +303,7 @@ public:
SkAutoGlyphCacheNoGamma(const SkPaint& paint,
const SkSurfaceProps* surfaceProps,
const SkMatrix* matrix)
- : SkAutoGlyphCache(paint, surfaceProps, SkPaint::FakeGamma::Off, matrix)
+ : SkAutoGlyphCache(paint, surfaceProps, SkPaint::kNone_FontWeightFlag, matrix)
{}
};
#define SkAutoGlyphCache(...) SK_REQUIRE_LOCAL_VAR(SkAutoGlyphCache)

Powered by Google App Engine
This is Rietveld 408576698