| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2011 The Android Open Source Project | 2 * Copyright 2011 The Android Open Source Project |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license that can be | 4 * Use of this source code is governed by a BSD-style license that can be |
| 5 * found in the LICENSE file. | 5 * found in the LICENSE file. |
| 6 */ | 6 */ |
| 7 | 7 |
| 8 #ifndef SkBlurImageFilter_DEFINED | 8 #ifndef SkBlurImageFilter_DEFINED |
| 9 #define SkBlurImageFilter_DEFINED | 9 #define SkBlurImageFilter_DEFINED |
| 10 | 10 |
| 11 #include "SkImageFilter.h" | 11 #include "SkImageFilter.h" |
| 12 #include "SkSize.h" | 12 #include "SkSize.h" |
| 13 | 13 |
| 14 class SK_API SkBlurImageFilter : public SkImageFilter { | 14 class SK_API SkBlurImageFilter : public SkImageFilter { |
| 15 typedef SkImageFilter INHERITED; |
| 16 |
| 15 public: | 17 public: |
| 16 SkBlurImageFilter(SkScalar sigmaX, | 18 SkBlurImageFilter(SkScalar sigmaX, |
| 17 SkScalar sigmaY, | 19 SkScalar sigmaY, |
| 18 SkImageFilter* input = NULL, | 20 SkImageFilter* input = NULL, |
| 19 const SkIRect* cropRect = NULL); | 21 const SkIRect* cropRect = NULL); |
| 20 | 22 |
| 21 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkBlurImageFilter) | 23 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkBlurImageFilter) |
| 22 | 24 |
| 23 protected: | 25 protected: |
| 24 explicit SkBlurImageFilter(SkFlattenableReadBuffer& buffer); | 26 explicit SkBlurImageFilter(SkFlattenableReadBuffer& buffer); |
| 25 virtual void flatten(SkFlattenableWriteBuffer&) const SK_OVERRIDE; | 27 virtual void flatten(SkFlattenableWriteBuffer&) const SK_OVERRIDE; |
| 26 | 28 |
| 27 virtual bool onFilterImage(Proxy*, const SkBitmap& src, const SkMatrix&, | 29 virtual bool onFilterImage(Proxy*, const SkBitmap& src, const SkMatrix&, |
| 28 SkBitmap* result, SkIPoint* offset) SK_OVERRIDE; | 30 SkBitmap* result, SkIPoint* offset) SK_OVERRIDE; |
| 29 | 31 |
| 30 bool canFilterImageGPU() const SK_OVERRIDE { return true; } | 32 bool canFilterImageGPU() const SK_OVERRIDE { return true; } |
| 31 virtual bool filterImageGPU(Proxy* proxy, const SkBitmap& src, const SkMatri
x& ctm, | 33 virtual bool filterImageGPU(Proxy* proxy, const SkBitmap& src, const SkMatri
x& ctm, |
| 32 SkBitmap* result, SkIPoint* offset) SK_OVERRIDE; | 34 SkBitmap* result, SkIPoint* offset) SK_OVERRIDE; |
| 33 | 35 |
| 34 private: | 36 private: |
| 35 SkSize fSigma; | 37 SkSize fSigma; |
| 36 typedef SkImageFilter INHERITED; | |
| 37 }; | 38 }; |
| 38 | 39 |
| 39 #endif | 40 #endif |
| OLD | NEW |