From 34ec37458b0a6e157912e0ff6ee8e136885474b9 Mon Sep 17 00:00:00 2001 From: Brian Osman Date: Tue, 3 Jul 2018 10:40:57 -0400 Subject: Replace isGammaCorrect with isLinearlyBlended We were using isGammaCorrect (presence of a color space) to trigger rendering effects that should only apply when doing linear blending. Rename and redefine that function to fix many of those issues. In a few places, we really do care about the color space. The big win here is text rendering, which is now the same on legacy gl and glsrgb configs. Also left some comments about our desire to do something smarter for text in the future. Bug: skia: Change-Id: I94106e95f5f81aaa0a28dbaccd65f5d94cf0de67 Reviewed-on: https://skia-review.googlesource.com/139109 Commit-Queue: Brian Osman Auto-Submit: Brian Osman Reviewed-by: Ben Wagner Reviewed-by: Mike Klein --- src/effects/SkHighContrastFilter.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/effects') diff --git a/src/effects/SkHighContrastFilter.cpp b/src/effects/SkHighContrastFilter.cpp index 607033ef20..be6180a531 100644 --- a/src/effects/SkHighContrastFilter.cpp +++ b/src/effects/SkHighContrastFilter.cpp @@ -364,7 +364,7 @@ void GLHighContrastFilterEffect::emitCode(EmitArgs& args) { std::unique_ptr SkHighContrast_Filter::asFragmentProcessor( GrContext*, const GrColorSpaceInfo& csi) const { - bool linearize = !csi.isGammaCorrect(); + bool linearize = !csi.isLinearlyBlended(); return HighContrastFilterEffect::Make(fConfig, linearize); } #endif -- cgit v1.2.3