diff options
author | brianosman <brianosman@google.com> | 2016-04-08 06:47:54 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-04-08 06:47:54 -0700 |
commit | a1e8f8d8f1a0b7141136d7d49df1cc2fec0528df (patch) | |
tree | 9249c051645ac31322729f11d3caa4c619aa7b73 /src/ports | |
parent | b63c5766c3dece300167b41c5c4e30b7b330dfaa (diff) |
Decouple contrast boost from fake gamma.
Replace FakeGamma with FontWeightFlags. Largely mechanical, except for
the changes in ignorePreBlend. With this change, text GMs generally look
the same (or at least more similar) in 8888/srgb/gpu/gpusrgb configs.
No public API changes.
TBR=reed@google.com
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1866293003
Review URL: https://codereview.chromium.org/1866293003
Diffstat (limited to 'src/ports')
-rw-r--r-- | src/ports/SkFontHost_FreeType.cpp | 3 | ||||
-rw-r--r-- | src/ports/SkFontHost_mac.cpp | 1 |
2 files changed, 3 insertions, 1 deletions
diff --git a/src/ports/SkFontHost_FreeType.cpp b/src/ports/SkFontHost_FreeType.cpp index 5c00d1b697..44eb50ce40 100644 --- a/src/ports/SkFontHost_FreeType.cpp +++ b/src/ports/SkFontHost_FreeType.cpp @@ -714,7 +714,8 @@ void SkTypeface_FreeType::onFilterRec(SkScalerContextRec* rec) const { #ifndef SK_GAMMA_APPLY_TO_A8 if (!isLCD(*rec)) { - rec->ignorePreBlend(); + // SRGBTODO: Is this correct? Do we want contrast boost? + rec->ignorePreBlend(); } #endif } diff --git a/src/ports/SkFontHost_mac.cpp b/src/ports/SkFontHost_mac.cpp index 53d5610575..29b52ca9d5 100644 --- a/src/ports/SkFontHost_mac.cpp +++ b/src/ports/SkFontHost_mac.cpp @@ -2030,6 +2030,7 @@ void SkTypeface_Mac::onFilterRec(SkScalerContextRec* rec) const { // All other masks can use regular gamma. if (SkMask::kA8_Format == rec->fMaskFormat && SkPaint::kNo_Hinting == hinting) { #ifndef SK_GAMMA_APPLY_TO_A8 + // SRGBTODO: Is this correct? Do we want contrast boost? rec->ignorePreBlend(); #endif } else { |