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

Unified Diff: src/ports/SkFontHost_FreeType.cpp

Issue 864903002: Lcd request early check in SkFontHost_FreeType::onFilterRec. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 11 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ports/SkFontHost_FreeType.cpp
diff --git a/src/ports/SkFontHost_FreeType.cpp b/src/ports/SkFontHost_FreeType.cpp
index 167c38b6670e81878bfcef6e2b67855306b7716e..ce762d82214170661d8e7e4bd7195434b90d5c6f 100644
--- a/src/ports/SkFontHost_FreeType.cpp
+++ b/src/ports/SkFontHost_FreeType.cpp
@@ -697,11 +697,11 @@ void SkTypeface_FreeType::onFilterRec(SkScalerContextRec* rec) const {
rec->fTextSize = SkIntToScalar(1 << 14);
}
- {
+ if (isLCD(*rec)) {
// TODO: re-work so that FreeType is set-up and selected by the SkFontMgr.
SkAutoMutexAcquire ama(gFTMutex);
ref_ft_library();
- if (!gFTLibrary->isLCDSupported() && isLCD(*rec)) {
+ if (!gFTLibrary->isLCDSupported()) {
// If the runtime Freetype library doesn't support LCD, disable it here.
rec->fMaskFormat = SkMask::kA8_Format;
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698