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

Unified Diff: include/effects/SkBlurImageFilter.h

Issue 1518643002: SkBlurImageFilter returns input when sigma = 0 (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: clean up code Created 5 years 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/effects/SkBlurImageFilter.h
diff --git a/include/effects/SkBlurImageFilter.h b/include/effects/SkBlurImageFilter.h
index 7f62634a9eb9b6d58bcc2c72c85d5dae2c2bc527..32e010cbcd245efba2aefcbf44fae2a67323378c 100644
--- a/include/effects/SkBlurImageFilter.h
+++ b/include/effects/SkBlurImageFilter.h
@@ -15,6 +15,8 @@ class SK_API SkBlurImageFilter : public SkImageFilter {
public:
static SkImageFilter* Create(SkScalar sigmaX, SkScalar sigmaY, SkImageFilter* input = NULL,
const CropRect* cropRect = NULL) {
+ if (0.0f == sigmaX && 0.0f == sigmaY && NULL == cropRect)
Stephen White 2015/12/10 16:05:40 Skia coding style requires braces on all statement
xidachen 2015/12/10 16:17:44 Done.
+ return input;
return new SkBlurImageFilter(sigmaX, sigmaY, input, cropRect);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698