| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2012 Google Inc. | 3 * Copyright 2012 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 | 9 |
| 10 #include "GrStencilAndCoverPathRenderer.h" | 10 #include "GrStencilAndCoverPathRenderer.h" |
| 11 #include "GrCaps.h" |
| 11 #include "GrContext.h" | 12 #include "GrContext.h" |
| 12 #include "GrDrawTargetCaps.h" | 13 #include "GrGpu.h" |
| 13 #include "GrPath.h" | 14 #include "GrPath.h" |
| 14 #include "GrRenderTarget.h" | 15 #include "GrRenderTarget.h" |
| 15 #include "GrResourceProvider.h" | 16 #include "GrResourceProvider.h" |
| 16 #include "GrStrokeInfo.h" | 17 #include "GrStrokeInfo.h" |
| 17 | 18 |
| 18 /* | 19 /* |
| 19 * For now paths only natively support winding and even odd fill types | 20 * For now paths only natively support winding and even odd fill types |
| 20 */ | 21 */ |
| 21 static GrPathRendering::FillType convert_skpath_filltype(SkPath::FillType fill)
{ | 22 static GrPathRendering::FillType convert_skpath_filltype(SkPath::FillType fill)
{ |
| 22 switch (fill) { | 23 switch (fill) { |
| (...skipping 129 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 152 0xffff); | 153 0xffff); |
| 153 | 154 |
| 154 pipelineBuilder->setStencil(kStencilPass); | 155 pipelineBuilder->setStencil(kStencilPass); |
| 155 SkAutoTUnref<GrPathProcessor> pp(GrPathProcessor::Create(color, viewMatr
ix)); | 156 SkAutoTUnref<GrPathProcessor> pp(GrPathProcessor::Create(color, viewMatr
ix)); |
| 156 target->drawPath(pipelineBuilder, pp, p, convert_skpath_filltype(path.ge
tFillType())); | 157 target->drawPath(pipelineBuilder, pp, p, convert_skpath_filltype(path.ge
tFillType())); |
| 157 } | 158 } |
| 158 | 159 |
| 159 pipelineBuilder->stencil()->setDisabled(); | 160 pipelineBuilder->stencil()->setDisabled(); |
| 160 return true; | 161 return true; |
| 161 } | 162 } |
| OLD | NEW |