OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2014 Google Inc. | 2 * Copyright 2014 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 "gm.h" | 8 #include "gm.h" |
9 #include "SkCanvas.h" | 9 #include "SkCanvas.h" |
10 #include "SkColorFilter.h" | 10 #include "SkColorFilter.h" |
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
89 | 89 |
90 Draw(canvas, checkerboard, rect, SkDilateImageFilter::Make(2, 2, | 90 Draw(canvas, checkerboard, rect, SkDilateImageFilter::Make(2, 2, |
91 noopCropp
ed, | 91 noopCropp
ed, |
92 &bigRect)
); | 92 &bigRect)
); |
93 | 93 |
94 Draw(canvas, checkerboard, rect, SkErodeImageFilter::Make(2, 2, | 94 Draw(canvas, checkerboard, rect, SkErodeImageFilter::Make(2, 2, |
95 noopCroppe
d, | 95 noopCroppe
d, |
96 &bigRect))
; | 96 &bigRect))
; |
97 | 97 |
98 Draw(canvas, checkerboard, rect, | 98 Draw(canvas, checkerboard, rect, |
99 sk_sp<SkImageFilter>(SkDropShadowImageFilter::Create( | 99 SkDropShadowImageFilter::Make( |
100 SkIntToScalar(10), | 100 SkIntToScalar(10), |
101 SkIntToScalar(10), | 101 SkIntToScalar(10), |
102 SkIntToScalar(3), | 102 SkIntToScalar(3), |
103 SkIntToScalar(3), | 103 SkIntToScalar(3), |
104 SK_ColorBLUE, | 104 SK_ColorBLUE, |
105 SkDropShadowImageFilter::kDrawShadowAndForeg
round_ShadowMode, | 105 SkDropShadowImageFilter::kDrawShadowAndForeg
round_ShadowMode, |
106 noopCropped.get(), | 106 noopCropped, |
107 &bigRect))); | 107 &bigRect)); |
108 | 108 |
109 Draw(canvas, checkerboard, rect, | 109 Draw(canvas, checkerboard, rect, |
110 sk_sp<SkImageFilter>(SkDisplacementMapEffect::Create( | 110 sk_sp<SkImageFilter>(SkDisplacementMapEffect::Create( |
111 SkDisplacementMapEffect::kR_Chan
nelSelectorType, | 111 SkDisplacementMapEffect::kR_Chan
nelSelectorType, |
112 SkDisplacementMapEffect::kR_Chan
nelSelectorType, | 112 SkDisplacementMapEffect::kR_Chan
nelSelectorType, |
113 SkIntToScalar(12), | 113 SkIntToScalar(12), |
114 gradientCircleSource.get(), | 114 gradientCircleSource.get(), |
115 noopCropped.get(), | 115 noopCropped.get(), |
116 &bigRect))); | 116 &bigRect))); |
117 | 117 |
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 | 188 |
189 canvas->translate(SkIntToScalar(80), 0); | 189 canvas->translate(SkIntToScalar(80), 0); |
190 } | 190 } |
191 | 191 |
192 typedef GM INHERITED; | 192 typedef GM INHERITED; |
193 }; | 193 }; |
194 | 194 |
195 /////////////////////////////////////////////////////////////////////////////// | 195 /////////////////////////////////////////////////////////////////////////////// |
196 | 196 |
197 DEF_GM( return new ImageFiltersCropExpandGM; ) | 197 DEF_GM( return new ImageFiltersCropExpandGM; ) |
OLD | NEW |