diff options
author | 2016-09-22 14:50:58 -0700 | |
---|---|---|
committer | 2016-09-22 14:50:58 -0700 | |
commit | 5a9c2f110e4f1a78d9bfedcf708168909706d7fd (patch) | |
tree | 615e7b191814888f8cb88043d85bf9b5472eff5f /src/effects/SkDisplacementMapEffect.cpp | |
parent | c68e8924c57487f39d5647f6e68bde522940b728 (diff) |
sRGB cleanup in image filters. Ensure we configure paints correctly.
Net effect of the two calls is (basically) the same, but given that we're
propagating from isGammaCorrect on the DC, I figured it makes sense to use
the same-named API.
More importantly, a couple places had slipped through, so those draws would
ignore sRGB-ness of inputs entirely.
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2357413004
Review-Url: https://codereview.chromium.org/2357413004
Diffstat (limited to 'src/effects/SkDisplacementMapEffect.cpp')
-rw-r--r-- | src/effects/SkDisplacementMapEffect.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/effects/SkDisplacementMapEffect.cpp b/src/effects/SkDisplacementMapEffect.cpp index 8fc0ec1366..8d068072a7 100644 --- a/src/effects/SkDisplacementMapEffect.cpp +++ b/src/effects/SkDisplacementMapEffect.cpp @@ -344,6 +344,7 @@ sk_sp<SkSpecialImage> SkDisplacementMapEffect::onFilterImage(SkSpecialImage* sou if (!drawContext) { return nullptr; } + paint.setGammaCorrect(drawContext->isGammaCorrect()); drawContext->drawRect(GrNoClip(), paint, matrix, SkRect::Make(colorBounds)); |