| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2013 Google Inc. | 2 * Copyright 2013 Google Inc. |
| 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 #include "SkColor.h" | 8 #include "SkColor.h" |
| 9 #include "SkImageFilter.h" | 9 #include "SkImageFilter.h" |
| 10 #include "SkScalar.h" | 10 #include "SkScalar.h" |
| 11 | 11 |
| 12 class SK_API SkDropShadowImageFilter : public SkImageFilter { | 12 class SK_API SkDropShadowImageFilter : public SkImageFilter { |
| 13 public: | 13 public: |
| 14 SkDropShadowImageFilter(SkScalar dx, SkScalar dy, SkScalar sigma, SkColor, S
kImageFilter* input = NULL); | 14 SkDropShadowImageFilter(SkScalar dx, SkScalar dy, SkScalar sigma, SkColor, S
kImageFilter* input = NULL); |
| 15 SkDropShadowImageFilter(SkScalar dx, SkScalar dy, SkScalar sigmaX, SkScalar
sigmaY, SkColor, SkImageFilter* input = NULL, const CropRect* cropRect = NULL); | 15 SkDropShadowImageFilter(SkScalar dx, SkScalar dy, SkScalar sigmaX, SkScalar
sigmaY, SkColor, SkImageFilter* input = NULL, const CropRect* cropRect = NULL); |
| 16 virtual void computeFastBounds(const SkRect&, SkRect*) const SK_OVERRIDE; |
| 16 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkDropShadowImageFilter) | 17 SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkDropShadowImageFilter) |
| 17 | 18 |
| 18 protected: | 19 protected: |
| 19 explicit SkDropShadowImageFilter(SkFlattenableReadBuffer&); | 20 explicit SkDropShadowImageFilter(SkFlattenableReadBuffer&); |
| 20 virtual void flatten(SkFlattenableWriteBuffer&) const SK_OVERRIDE; | 21 virtual void flatten(SkFlattenableWriteBuffer&) const SK_OVERRIDE; |
| 21 virtual bool onFilterImage(Proxy*, const SkBitmap& source, const SkMatrix&,
SkBitmap* result, SkIPoint* loc) SK_OVERRIDE; | 22 virtual bool onFilterImage(Proxy*, const SkBitmap& source, const SkMatrix&,
SkBitmap* result, SkIPoint* loc) SK_OVERRIDE; |
| 22 | 23 |
| 23 private: | 24 private: |
| 24 SkScalar fDx, fDy, fSigmaX, fSigmaY; | 25 SkScalar fDx, fDy, fSigmaX, fSigmaY; |
| 25 SkColor fColor; | 26 SkColor fColor; |
| 26 typedef SkImageFilter INHERITED; | 27 typedef SkImageFilter INHERITED; |
| 27 }; | 28 }; |
| OLD | NEW |