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

Unified Diff: src/core/SkScalerContext.h

Issue 1866293003: Decouple contrast boost from fake gamma. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Improve ignorePreBlend API, add storage type to enum 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
« no previous file with comments | « src/core/SkPaint.cpp ('k') | src/gpu/text/GrAtlasTextBlob.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkScalerContext.h
diff --git a/src/core/SkScalerContext.h b/src/core/SkScalerContext.h
index f2df93cef31ad611c79fd8bf3f9c003778753829..96674cd5002a8934df2af4a9933834d7345bf1ad 100644
--- a/src/core/SkScalerContext.h
+++ b/src/core/SkScalerContext.h
@@ -68,13 +68,21 @@ struct SkScalerContextRec {
}
/**
- * Causes the luminance color and contrast to be ignored, and the
- * paint and device gamma to be effectively 1.0.
+ * Causes the luminance color to be ignored, and the paint and device
+ * gamma to be effectively 1.0
*/
- void ignorePreBlend() {
+ void ignoreGamma() {
setLuminanceColor(SK_ColorTRANSPARENT);
setPaintGamma(SK_Scalar1);
setDeviceGamma(SK_Scalar1);
+ }
+
+ /**
+ * Causes the luminance color and contrast to be ignored, and the
+ * paint and device gamma to be effectively 1.0.
+ */
+ void ignorePreBlend() {
+ ignoreGamma();
setContrast(0);
}
« no previous file with comments | « src/core/SkPaint.cpp ('k') | src/gpu/text/GrAtlasTextBlob.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698