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 | 9 |
10 #include "Resources.h" | 10 #include "Resources.h" |
11 #include "SampleCode.h" | 11 #include "SampleCode.h" |
12 #include "SkBlurMaskFilter.h" | 12 #include "SkBlurMaskFilter.h" |
13 #include "SkCanvas.h" | 13 #include "SkCanvas.h" |
14 #include "SkColorPriv.h" | 14 #include "SkColorPriv.h" |
15 #include "SkImageDecoder.h" | 15 #include "SkImageDecoder.h" |
| 16 #include "SkPath.h" |
16 #include "SkRandom.h" | 17 #include "SkRandom.h" |
17 #include "SkStream.h" | 18 #include "SkStream.h" |
18 #include "SkTime.h" | 19 #include "SkTime.h" |
19 | 20 |
20 // Intended to exercise pixel snapping observed with scaled images (and | 21 // Intended to exercise pixel snapping observed with scaled images (and |
21 // with non-scaled images, but for a different reason): Bug 1145 | 22 // with non-scaled images, but for a different reason): Bug 1145 |
22 | 23 |
23 class IdentityScaleView : public SampleView { | 24 class IdentityScaleView : public SampleView { |
24 public: | 25 public: |
25 IdentityScaleView(const char imageFilename[]) { | 26 IdentityScaleView(const char imageFilename[]) { |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 } | 84 } |
84 | 85 |
85 private: | 86 private: |
86 typedef SampleView INHERITED; | 87 typedef SampleView INHERITED; |
87 }; | 88 }; |
88 | 89 |
89 ////////////////////////////////////////////////////////////////////////////// | 90 ////////////////////////////////////////////////////////////////////////////// |
90 | 91 |
91 static SkView* MyFactory() { return new IdentityScaleView("mandrill_256.png"); } | 92 static SkView* MyFactory() { return new IdentityScaleView("mandrill_256.png"); } |
92 static SkViewRegister reg(MyFactory); | 93 static SkViewRegister reg(MyFactory); |
OLD | NEW |