Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(109)

Side by Side Diff: src/gpu/batches/GrDashLinePathRenderer.cpp

Issue 2165283002: Remove DrawFace enum from GrPipelineBuilder (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: try again Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/gpu/GrSoftwarePathRenderer.cpp ('k') | src/gpu/batches/GrDefaultPathRenderer.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2015 Google Inc. 2 * Copyright 2015 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 #include "GrDashLinePathRenderer.h" 8 #include "GrDashLinePathRenderer.h"
9 9
10 #include "GrAuditTrail.h"
10 #include "GrGpu.h" 11 #include "GrGpu.h"
11 #include "GrAuditTrail.h" 12 #include "GrPipelineBuilder.h"
12 #include "effects/GrDashingEffect.h" 13 #include "effects/GrDashingEffect.h"
13 14
14 bool GrDashLinePathRenderer::onCanDrawPath(const CanDrawPathArgs& args) const { 15 bool GrDashLinePathRenderer::onCanDrawPath(const CanDrawPathArgs& args) const {
15 SkPoint pts[2]; 16 SkPoint pts[2];
16 bool inverted; 17 bool inverted;
17 if (args.fShape->style().isDashed() && args.fShape->asLine(pts, &inverted)) { 18 if (args.fShape->style().isDashed() && args.fShape->asLine(pts, &inverted)) {
18 // We should never have an inverse dashed case. 19 // We should never have an inverse dashed case.
19 SkASSERT(!inverted); 20 SkASSERT(!inverted);
20 return GrDashingEffect::CanDrawDashLine(pts, args.fShape->style(), *args .fViewMatrix); 21 return GrDashingEffect::CanDrawDashLine(pts, args.fShape->style(), *args .fViewMatrix);
21 } 22 }
(...skipping 24 matching lines...) Expand all
46 if (!batch) { 47 if (!batch) {
47 return false; 48 return false;
48 } 49 }
49 50
50 GrPipelineBuilder pipelineBuilder(*args.fPaint, useHWAA); 51 GrPipelineBuilder pipelineBuilder(*args.fPaint, useHWAA);
51 pipelineBuilder.setUserStencil(args.fUserStencilSettings); 52 pipelineBuilder.setUserStencil(args.fUserStencilSettings);
52 53
53 args.fDrawContext->drawBatch(pipelineBuilder, *args.fClip, batch); 54 args.fDrawContext->drawBatch(pipelineBuilder, *args.fClip, batch);
54 return true; 55 return true;
55 } 56 }
OLDNEW
« no previous file with comments | « src/gpu/GrSoftwarePathRenderer.cpp ('k') | src/gpu/batches/GrDefaultPathRenderer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698