Chromium Code Reviews| Index: gm/imagefiltersbase.cpp |
| diff --git a/gm/imagefiltersbase.cpp b/gm/imagefiltersbase.cpp |
| index be4325ef1fffa2ca65c0ebbdcd2ebfacf513296b..e2e92356e09f49e0777032e82a3c3d115ebc0d4b 100644 |
| --- a/gm/imagefiltersbase.cpp |
| +++ b/gm/imagefiltersbase.cpp |
| @@ -14,6 +14,7 @@ |
| #include "SkBlurImageFilter.h" |
| #include "SkColorFilterImageFilter.h" |
| #include "SkDropShadowImageFilter.h" |
| +#include "SkSpecialImage.h" |
| #include "SkTestImageFilters.h" |
| class FailImageFilter : public SkImageFilter { |
| @@ -36,9 +37,9 @@ public: |
| protected: |
| FailImageFilter() : INHERITED(nullptr, 0, nullptr) {} |
| - bool onFilterImageDeprecated(Proxy*, const SkBitmap& src, const Context&, |
| - SkBitmap* result, SkIPoint* offset) const override { |
| - return false; |
| + sk_sp<SkSpecialImage> onFilterImage(SkSpecialImage* source, const Context&, |
| + SkIPoint* offset) const override { |
| + return nullptr; |
| } |
| private: |
| @@ -77,11 +78,10 @@ public: |
| SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(IdentityImageFilter) |
| protected: |
| - bool onFilterImageDeprecated(Proxy*, const SkBitmap& src, const Context&, |
| - SkBitmap* result, SkIPoint* offset) const override { |
| - *result = src; |
| + sk_sp<SkSpecialImage> onFilterImage(SkSpecialImage* source, const Context&, |
| + SkIPoint* offset) const override { |
| offset->set(0, 0); |
| - return true; |
| + return sk_ref_sp<SkSpecialImage>(source); |
|
Stephen White
2016/04/04 17:02:42
Let's not do this until we get the null_ptr-as-tra
robertphillips
2016/04/04 18:08:31
I seems like this is actually what this test image
Stephen White
2016/04/04 18:43:15
Oh! Yeah, I guess it does. It's returning the sour
|
| } |
| private: |