OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2011 Google Inc. | 2 * Copyright 2011 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 #include "gm.h" | 7 #include "gm.h" |
| 8 #include "SkColorFilter.h" |
| 9 #include "SkMaskFilter.h" |
8 #include "SkPath.h" | 10 #include "SkPath.h" |
9 #include "SkRegion.h" | 11 #include "SkRegion.h" |
10 #include "SkShader.h" | 12 #include "SkShader.h" |
11 #include "SkUtils.h" | 13 #include "SkUtils.h" |
12 #include "SkColorFilter.h" | |
13 | 14 |
14 // effects | 15 // effects |
15 #include "SkGradientShader.h" | 16 #include "SkGradientShader.h" |
16 #include "SkBlurDrawLooper.h" | 17 #include "SkBlurDrawLooper.h" |
17 | 18 |
18 static void makebm(SkBitmap* bm, SkColorType ct, int w, int h) { | 19 static void makebm(SkBitmap* bm, SkColorType ct, int w, int h) { |
19 bm->allocPixels(SkImageInfo::Make(w, h, ct, kPremul_SkAlphaType)); | 20 bm->allocPixels(SkImageInfo::Make(w, h, ct, kPremul_SkAlphaType)); |
20 bm->eraseColor(SK_ColorTRANSPARENT); | 21 bm->eraseColor(SK_ColorTRANSPARENT); |
21 | 22 |
22 SkCanvas canvas(*bm); | 23 SkCanvas canvas(*bm); |
(...skipping 234 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
257 private: | 258 private: |
258 typedef skiagm::GM INHERITED; | 259 typedef skiagm::GM INHERITED; |
259 }; | 260 }; |
260 | 261 |
261 ////////////////////////////////////////////////////////////////////////////// | 262 ////////////////////////////////////////////////////////////////////////////// |
262 | 263 |
263 DEF_GM( return new ScaledTilingGM(true); ) | 264 DEF_GM( return new ScaledTilingGM(true); ) |
264 DEF_GM( return new ScaledTilingGM(false); ) | 265 DEF_GM( return new ScaledTilingGM(false); ) |
265 DEF_GM( return new ScaledTiling2GM(make_bm, "bitmap"); ) | 266 DEF_GM( return new ScaledTiling2GM(make_bm, "bitmap"); ) |
266 DEF_GM( return new ScaledTiling2GM(make_grad, "gradient"); ) | 267 DEF_GM( return new ScaledTiling2GM(make_grad, "gradient"); ) |
OLD | NEW |