Beginning to refactor nvpr code
BUG=skia:
Review URL: https://codereview.chromium.org/687563008
diff --git a/src/gpu/GrPathRendering.h b/src/gpu/GrPathRendering.h
index 26cfa11..cd42206 100644
--- a/src/gpu/GrPathRendering.h
+++ b/src/gpu/GrPathRendering.h
@@ -16,6 +16,7 @@
class SkTypeface;
class GrPath;
class GrGpu;
+class GrStencilSettings;
/**
* Abstract class wrapping HW path rendering API.
@@ -33,6 +34,18 @@
public:
virtual ~GrPathRendering() { }
+ // No native support for inverse at this time
+ enum FillType {
+ /** Specifies that "inside" is computed by a non-zero sum of signed
+ edge crossings
+ */
+ kWinding_FillType,
+ /** Specifies that "inside" is computed by an odd number of edge
+ crossings
+ */
+ kEvenOdd_FillType,
+ };
+
enum PathTransformType {
kNone_PathTransformType, //!< []
kTranslateX_PathTransformType, //!< [kMTransX]
@@ -111,10 +124,11 @@
*/
virtual GrPathRange* createGlyphs(const SkTypeface*, const SkDescriptor*, const SkStrokeRec&) = 0;
- virtual void stencilPath(const GrPath*, SkPath::FillType) = 0;
- virtual void drawPath(const GrPath*, SkPath::FillType) = 0;
+ virtual void stencilPath(const GrPath*, const GrStencilSettings&) = 0;
+ virtual void drawPath(const GrPath*, const GrStencilSettings&) = 0;
virtual void drawPaths(const GrPathRange*, const uint32_t indices[], int count,
- const float transforms[], PathTransformType, SkPath::FillType) = 0;
+ const float transforms[], PathTransformType,
+ const GrStencilSettings&) = 0;
protected:
GrPathRendering() { }