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 public: | 15 public: |
16 SkBlurImageFilter(SkScalar sigmaX, SkScalar sigmaY, SkImageFilter* input = N
ULL); | 16 SkBlurImageFilter(SkScalar sigmaX, SkScalar sigmaY, SkImageFilter* input = N
ULL); |
17 | 17 |
18 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkBlurImageFilter) | 18 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkBlurImageFilter) |
19 | 19 |
20 protected: | 20 protected: |
21 explicit SkBlurImageFilter(SkFlattenableReadBuffer& buffer); | 21 explicit SkBlurImageFilter(SkFlattenableReadBuffer& buffer); |
22 virtual void flatten(SkFlattenableWriteBuffer&) const SK_OVERRIDE; | 22 virtual void flatten(SkFlattenableWriteBuffer&) const SK_OVERRIDE; |
23 | 23 |
24 virtual bool onFilterImage(Proxy*, const SkBitmap& src, const SkMatrix&, | 24 virtual bool onFilterImage(Proxy*, const SkBitmap& src, const SkMatrix&, |
25 SkBitmap* result, SkIPoint* offset) SK_OVERRIDE; | 25 SkBitmap* result, SkIPoint* offset) SK_OVERRIDE; |
26 | 26 |
27 bool canFilterImageGPU() const SK_OVERRIDE { return true; } | 27 bool canFilterImageGPU() const SK_OVERRIDE { return true; } |
28 virtual bool filterImageGPU(Proxy* proxy, const SkBitmap& src, SkBitmap* res
ult) SK_OVERRIDE; | 28 virtual bool filterImageGPU(Proxy* proxy, const SkBitmap& src, SkBitmap* res
ult, |
| 29 SkIPoint* offset) SK_OVERRIDE; |
29 | 30 |
30 private: | 31 private: |
31 SkSize fSigma; | 32 SkSize fSigma; |
32 typedef SkImageFilter INHERITED; | 33 typedef SkImageFilter INHERITED; |
33 }; | 34 }; |
34 | 35 |
35 #endif | 36 #endif |
OLD | NEW |