OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2013 Google Inc. | 3 * Copyright 2013 Google Inc. |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 #include "gm.h" | 8 #include "gm.h" |
9 #include "SkBitmap.h" | 9 #include "SkBitmap.h" |
10 #include "SkRandom.h" | 10 #include "SkRandom.h" |
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
83 txtPaint.setAntiAlias(true); | 83 txtPaint.setAntiAlias(true); |
84 static const char kTxt[] = "Work in progres... Do not baseline."; | 84 static const char kTxt[] = "Work in progres... Do not baseline."; |
85 canvas->drawText(kTxt, strlen(kTxt), | 85 canvas->drawText(kTxt, strlen(kTxt), |
86 areaSqrt/50, | 86 areaSqrt/50, |
87 SkIntToScalar(size.fHeight / 2), | 87 SkIntToScalar(size.fHeight / 2), |
88 txtPaint); | 88 txtPaint); |
89 | 89 |
90 canvas->restore(); | 90 canvas->restore(); |
91 } | 91 } |
92 | 92 |
93 // https://code.google.com/p/skia/issues/detail?id=1199&thanks=1199&ts=13648
39297 | |
94 virtual uint32_t onGetFlags() const SK_OVERRIDE { return kSkipPipe_Flag; } | |
95 | |
96 private: | 93 private: |
97 enum { | 94 enum { |
98 kMinR = 10, | 95 kMinR = 10, |
99 kMaxR = 50, | 96 kMaxR = 50, |
100 kNumCircles = 50, | 97 kNumCircles = 50, |
101 }; | 98 }; |
102 SkAutoTUnref<SkShader> fBG; | 99 SkAutoTUnref<SkShader> fBG; |
103 typedef GM INHERITED; | 100 typedef GM INHERITED; |
104 }; | 101 }; |
105 | 102 |
106 ////////////////////////////////////////////////////////////////////////////// | 103 ////////////////////////////////////////////////////////////////////////////// |
107 | 104 |
108 static GM* MyFactory(void*) { return new MixedXfermodesGM; } | 105 static GM* MyFactory(void*) { return new MixedXfermodesGM; } |
109 static GMRegistry reg(MyFactory); | 106 static GMRegistry reg(MyFactory); |
110 | 107 |
111 } | 108 } |
OLD | NEW |