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

Side by Side Diff: src/gpu/GrSoftwarePathRenderer.h

Issue 1291803006: Simplify parameters passed to path renderers (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Add more validate methods Created 5 years, 4 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/GrPathRendererChain.cpp ('k') | src/gpu/GrSoftwarePathRenderer.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 /* 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 #ifndef GrSoftwarePathRenderer_DEFINED 9 #ifndef GrSoftwarePathRenderer_DEFINED
10 #define GrSoftwarePathRenderer_DEFINED 10 #define GrSoftwarePathRenderer_DEFINED
11 11
12 #include "GrPathRenderer.h" 12 #include "GrPathRenderer.h"
13 13
14 class GrContext; 14 class GrContext;
15 15
16 /** 16 /**
17 * This class uses the software side to render a path to an SkBitmap and 17 * This class uses the software side to render a path to an SkBitmap and
18 * then uploads the result to the gpu 18 * then uploads the result to the gpu
19 */ 19 */
20 class GrSoftwarePathRenderer : public GrPathRenderer { 20 class GrSoftwarePathRenderer : public GrPathRenderer {
21 public: 21 public:
22 GrSoftwarePathRenderer(GrContext* context) 22 GrSoftwarePathRenderer(GrContext* context)
23 : fContext(context) { 23 : fContext(context) {
24 } 24 }
25 private: 25 private:
26 virtual StencilSupport onGetStencilSupport(const GrDrawTarget*, 26 StencilSupport onGetStencilSupport(const SkPath&, const GrStrokeInfo&) const override {
27 const GrPipelineBuilder*, 27 return GrPathRenderer::kNoSupport_StencilSupport;
28 const SkPath&, 28 }
29 const GrStrokeInfo&) const overri de;
30 29
31 bool onCanDrawPath(const CanDrawPathArgs&) const override; 30 bool onCanDrawPath(const CanDrawPathArgs&) const override;
32 31
33 bool onDrawPath(const DrawPathArgs&) override; 32 bool onDrawPath(const DrawPathArgs&) override;
34 33
35 private: 34 private:
36 GrContext* fContext; 35 GrContext* fContext;
37 36
38 typedef GrPathRenderer INHERITED; 37 typedef GrPathRenderer INHERITED;
39 }; 38 };
40 39
41 #endif 40 #endif
OLDNEW
« no previous file with comments | « src/gpu/GrPathRendererChain.cpp ('k') | src/gpu/GrSoftwarePathRenderer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698