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

Unified Diff: src/effects/SkBlurImageFilter.cpp

Issue 1964413003: Revert of Make SkGpuBlurUtils::GaussianBlur more drawContext centric (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 4 years, 7 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 | src/effects/SkBlurMaskFilter.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/effects/SkBlurImageFilter.cpp
diff --git a/src/effects/SkBlurImageFilter.cpp b/src/effects/SkBlurImageFilter.cpp
index 0625d37a42a18c3b16539ebb11752add214a9b8e..4e1fde250bed74617a368d370e3703115b738b53 100644
--- a/src/effects/SkBlurImageFilter.cpp
+++ b/src/effects/SkBlurImageFilter.cpp
@@ -121,21 +121,20 @@
inputBounds.offset(-inputOffset);
dstBounds.offset(-inputOffset);
SkRect inputBoundsF(SkRect::Make(inputBounds));
- sk_sp<GrDrawContext> drawContext(SkGpuBlurUtils::GaussianBlur(
- context,
- inputTexture.get(),
- source->props().isGammaCorrect(),
- SkRect::Make(dstBounds),
- &inputBoundsF,
- sigma.x(),
- sigma.y()));
- if (!drawContext) {
+ sk_sp<GrTexture> tex(SkGpuBlurUtils::GaussianBlur(context,
+ inputTexture.get(),
+ source->props().isGammaCorrect(),
+ SkRect::Make(dstBounds),
+ &inputBoundsF,
+ sigma.x(),
+ sigma.y()));
+ if (!tex) {
return nullptr;
}
return SkSpecialImage::MakeFromGpu(SkIRect::MakeWH(dstBounds.width(), dstBounds.height()),
kNeedNewImageUniqueID_SpecialImage,
- drawContext->asTexture(), &source->props());
+ std::move(tex), &source->props());
}
#endif
« no previous file with comments | « no previous file | src/effects/SkBlurMaskFilter.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698