OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2014 Google Inc. | 3 * Copyright 2014 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 | 8 |
9 // This test only works with the GPU backend. | 9 // This test only works with the GPU backend. |
10 | 10 |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 SkPoint* verts = reinterpret_cast<SkPoint*>(helper.init(batchTarget, ver
texStride, 1)); | 57 SkPoint* verts = reinterpret_cast<SkPoint*>(helper.init(batchTarget, ver
texStride, 1)); |
58 if (!verts) { | 58 if (!verts) { |
59 return; | 59 return; |
60 } | 60 } |
61 | 61 |
62 // Make sure any artifacts around the exterior of path are visible by us
ing overly | 62 // Make sure any artifacts around the exterior of path are visible by us
ing overly |
63 // conservative bounding geometry. | 63 // conservative bounding geometry. |
64 fGeometry.fBounds.outset(5.f, 5.f); | 64 fGeometry.fBounds.outset(5.f, 5.f); |
65 fGeometry.fBounds.toQuad(verts); | 65 fGeometry.fBounds.toQuad(verts); |
66 | 66 |
67 helper.issueDraws(batchTarget); | 67 helper.issueDraw(batchTarget); |
68 } | 68 } |
69 | 69 |
70 Geometry fGeometry; | 70 Geometry fGeometry; |
71 | 71 |
72 typedef GrTestBatch INHERITED; | 72 typedef GrTestBatch INHERITED; |
73 }; | 73 }; |
74 | 74 |
75 /** | 75 /** |
76 * This GM directly exercises a GrProcessor that draws convex polygons. | 76 * This GM directly exercises a GrProcessor that draws convex polygons. |
77 */ | 77 */ |
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
261 SkTLList<SkPath> fPaths; | 261 SkTLList<SkPath> fPaths; |
262 SkTLList<SkRect> fRects; | 262 SkTLList<SkRect> fRects; |
263 | 263 |
264 typedef GM INHERITED; | 264 typedef GM INHERITED; |
265 }; | 265 }; |
266 | 266 |
267 DEF_GM( return SkNEW(ConvexPolyEffect); ) | 267 DEF_GM( return SkNEW(ConvexPolyEffect); ) |
268 } | 268 } |
269 | 269 |
270 #endif | 270 #endif |
OLD | NEW |