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

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

Issue 142543007: Revert of r13384 (Stateful PathRenderer implementation) (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 6 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « src/gpu/GrContext.cpp ('k') | src/gpu/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 2011 Google Inc. 2 * Copyright 2011 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 #ifndef GrDefaultPathRenderer_DEFINED 8 #ifndef GrDefaultPathRenderer_DEFINED
9 #define GrDefaultPathRenderer_DEFINED 9 #define GrDefaultPathRenderer_DEFINED
10 10
11 #include "GrPathRenderer.h" 11 #include "GrPathRenderer.h"
12 #include "SkTemplates.h" 12 #include "SkTemplates.h"
13 13
14 /** 14 /**
15 * Subclass that renders the path using the stencil buffer to resolve fill rule s 15 * Subclass that renders the path using the stencil buffer to resolve fill rule s
16 * (e.g. winding, even-odd) 16 * (e.g. winding, even-odd)
17 */ 17 */
18 class SK_API GrDefaultPathRenderer : public GrPathRenderer { 18 class SK_API GrDefaultPathRenderer : public GrPathRenderer {
19 public: 19 public:
20 GrDefaultPathRenderer(bool separateStencilSupport, bool stencilWrapOpsSuppor t); 20 GrDefaultPathRenderer(bool separateStencilSupport, bool stencilWrapOpsSuppor t);
21 21
22 virtual bool canDrawPath(const SkStrokeRec&, 22 virtual bool canDrawPath(const SkPath&,
23 const SkStrokeRec&,
23 const GrDrawTarget*, 24 const GrDrawTarget*,
24 bool antiAlias) const SK_OVERRIDE; 25 bool antiAlias) const SK_OVERRIDE;
25 26
26 private: 27 private:
27 28
28 virtual StencilSupport onGetStencilSupport(const SkStrokeRec&, 29 virtual StencilSupport onGetStencilSupport(const SkPath&,
30 const SkStrokeRec&,
29 const GrDrawTarget*) const SK_OVE RRIDE; 31 const GrDrawTarget*) const SK_OVE RRIDE;
30 32
31 virtual bool onDrawPath(const SkStrokeRec&, 33 virtual bool onDrawPath(const SkPath&,
34 const SkStrokeRec&,
32 GrDrawTarget*, 35 GrDrawTarget*,
33 bool antiAlias) SK_OVERRIDE; 36 bool antiAlias) SK_OVERRIDE;
34 37
35 virtual void onStencilPath(const SkStrokeRec&, 38 virtual void onStencilPath(const SkPath&,
39 const SkStrokeRec&,
36 GrDrawTarget*) SK_OVERRIDE; 40 GrDrawTarget*) SK_OVERRIDE;
37 41
38 bool internalDrawPath(const SkStrokeRec&, 42 bool internalDrawPath(const SkPath&,
43 const SkStrokeRec&,
39 GrDrawTarget*, 44 GrDrawTarget*,
40 bool stencilOnly); 45 bool stencilOnly);
41 46
42 bool createGeom(const SkPath&, 47 bool createGeom(const SkPath&,
43 const SkStrokeRec&, 48 const SkStrokeRec&,
44 SkScalar srcSpaceTol, 49 SkScalar srcSpaceTol,
45 GrDrawTarget*, 50 GrDrawTarget*,
46 GrPrimitiveType*, 51 GrPrimitiveType*,
47 int* vertexCnt, 52 int* vertexCnt,
48 int* indexCnt, 53 int* indexCnt,
49 GrDrawTarget::AutoReleaseGeometry*); 54 GrDrawTarget::AutoReleaseGeometry*);
50 55
51 bool fSeparateStencil; 56 bool fSeparateStencil;
52 bool fStencilWrapOps; 57 bool fStencilWrapOps;
53 58
54 typedef GrPathRenderer INHERITED; 59 typedef GrPathRenderer INHERITED;
55 }; 60 };
56 61
57 #endif 62 #endif
OLDNEW
« no previous file with comments | « src/gpu/GrContext.cpp ('k') | src/gpu/GrDefaultPathRenderer.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698