OLD | NEW |
1 /* | 1 /* |
2 * Copyright 2012 Google Inc. | 2 * Copyright 2012 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 | 9 |
10 #include "SkArithmeticMode.h" | 10 #include "SkArithmeticMode.h" |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 | 83 |
84 class ImageFiltersGraphGM : public skiagm::GM { | 84 class ImageFiltersGraphGM : public skiagm::GM { |
85 public: | 85 public: |
86 ImageFiltersGraphGM() : fInitialized(false) { | 86 ImageFiltersGraphGM() : fInitialized(false) { |
87 int dummy; | 87 int dummy; |
88 SK_DECLARE_STATIC_ONCE(once); | 88 SK_DECLARE_STATIC_ONCE(once); |
89 SkOnce(&once, init_flattenable, &dummy); | 89 SkOnce(&once, init_flattenable, &dummy); |
90 } | 90 } |
91 | 91 |
92 protected: | 92 protected: |
| 93 virtual uint32_t onGetFlags() const SK_OVERRIDE { |
| 94 return kSkipTiled_Flag; |
| 95 } |
| 96 |
93 virtual SkString onShortName() { | 97 virtual SkString onShortName() { |
94 return SkString("imagefiltersgraph"); | 98 return SkString("imagefiltersgraph"); |
95 } | 99 } |
96 | 100 |
97 void make_bitmap() { | 101 void make_bitmap() { |
98 fBitmap.allocN32Pixels(100, 100); | 102 fBitmap.allocN32Pixels(100, 100); |
99 SkCanvas canvas(fBitmap); | 103 SkCanvas canvas(fBitmap); |
100 canvas.clear(0x00000000); | 104 canvas.clear(0x00000000); |
101 SkPaint paint; | 105 SkPaint paint; |
102 paint.setAntiAlias(true); | 106 paint.setAntiAlias(true); |
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
211 private: | 215 private: |
212 typedef GM INHERITED; | 216 typedef GM INHERITED; |
213 SkBitmap fBitmap; | 217 SkBitmap fBitmap; |
214 bool fInitialized; | 218 bool fInitialized; |
215 }; | 219 }; |
216 | 220 |
217 /////////////////////////////////////////////////////////////////////////////// | 221 /////////////////////////////////////////////////////////////////////////////// |
218 | 222 |
219 static skiagm::GM* MyFactory(void*) { return new ImageFiltersGraphGM; } | 223 static skiagm::GM* MyFactory(void*) { return new ImageFiltersGraphGM; } |
220 static skiagm::GMRegistry reg(MyFactory); | 224 static skiagm::GMRegistry reg(MyFactory); |
OLD | NEW |