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