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 | 8 |
9 #include "GrStencilAndCoverPathRenderer.h" | 9 #include "GrStencilAndCoverPathRenderer.h" |
10 #include "GrCaps.h" | 10 #include "GrCaps.h" |
11 #include "GrContext.h" | 11 #include "GrContext.h" |
12 #include "GrDrawContextPriv.h" | 12 #include "GrDrawContextPriv.h" |
13 #include "GrDrawPathBatch.h" | 13 #include "GrDrawPathBatch.h" |
14 #include "GrGpu.h" | 14 #include "GrGpu.h" |
15 #include "GrPath.h" | 15 #include "GrPath.h" |
| 16 #include "GrPipelineBuilder.h" |
16 #include "GrRenderTarget.h" | 17 #include "GrRenderTarget.h" |
17 #include "GrResourceProvider.h" | 18 #include "GrResourceProvider.h" |
18 #include "GrStencilPathBatch.h" | 19 #include "GrStencilPathBatch.h" |
19 #include "GrStyle.h" | 20 #include "GrStyle.h" |
20 #include "batches/GrRectBatchFactory.h" | 21 #include "batches/GrRectBatchFactory.h" |
21 | 22 |
22 GrPathRenderer* GrStencilAndCoverPathRenderer::Create(GrResourceProvider* resour
ceProvider, | 23 GrPathRenderer* GrStencilAndCoverPathRenderer::Create(GrResourceProvider* resour
ceProvider, |
23 const GrCaps& caps) { | 24 const GrCaps& caps) { |
24 if (caps.shaderCaps()->pathRenderingSupport()) { | 25 if (caps.shaderCaps()->pathRenderingSupport()) { |
25 return new GrStencilAndCoverPathRenderer(resourceProvider); | 26 return new GrStencilAndCoverPathRenderer(resourceProvider); |
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 if (args.fAntiAlias) { | 164 if (args.fAntiAlias) { |
164 SkASSERT(args.fDrawContext->isStencilBufferMultisampled()); | 165 SkASSERT(args.fDrawContext->isStencilBufferMultisampled()); |
165 pipelineBuilder.enableState(GrPipelineBuilder::kHWAntialias_Flag); | 166 pipelineBuilder.enableState(GrPipelineBuilder::kHWAntialias_Flag); |
166 } | 167 } |
167 | 168 |
168 args.fDrawContext->drawBatch(pipelineBuilder, *args.fClip, batch); | 169 args.fDrawContext->drawBatch(pipelineBuilder, *args.fClip, batch); |
169 } | 170 } |
170 | 171 |
171 return true; | 172 return true; |
172 } | 173 } |
OLD | NEW |