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

Unified Diff: src/core/SkBlurImageFilter.cpp

Issue 2357273002: Add output format properties to SkImageFilter::Context (Closed)
Patch Set: Spelling Created 4 years, 3 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/SkBitmapDevice.cpp ('k') | src/core/SkImageFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkBlurImageFilter.cpp
diff --git a/src/core/SkBlurImageFilter.cpp b/src/core/SkBlurImageFilter.cpp
index ccb3ed8fddc14496981b9beea4535ea9850c6819..78fa071acd74c1f186ff48a02ee55d7cd06b6467 100644
--- a/src/core/SkBlurImageFilter.cpp
+++ b/src/core/SkBlurImageFilter.cpp
@@ -157,6 +157,9 @@ sk_sp<SkSpecialImage> SkBlurImageFilterImpl::onFilterImage(SkSpecialImage* sourc
offset->fY = dstBounds.fTop;
inputBounds.offset(-inputOffset);
dstBounds.offset(-inputOffset);
+ // We intentionally use the source's color space, not the destination's (from ctx). We
+ // always blur in the source's config, so we need a compatible color space. We also want to
+ // avoid doing gamut conversion on every fetch of the texture.
sk_sp<GrDrawContext> drawContext(SkGpuBlurUtils::GaussianBlur(
context,
inputTexture.get(),
« no previous file with comments | « src/core/SkBitmapDevice.cpp ('k') | src/core/SkImageFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698