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

Unified Diff: src/gpu/GrSWMaskHelper.h

Issue 2006643005: Start on replacing path+style with shape in patherenderer (Closed) Base URL: https://chromium.googlesource.com/skia.git@master
Patch Set: rebase after breaking out more Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/gpu/GrPathRendererChain.cpp ('k') | src/gpu/GrSWMaskHelper.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrSWMaskHelper.h
diff --git a/src/gpu/GrSWMaskHelper.h b/src/gpu/GrSWMaskHelper.h
index fac4e6287eea5430fa49d8a13b49b2dc3a0a6a7f..ed4f70dc7750eae88f9d3e7ba6a2c35326d43a79 100644
--- a/src/gpu/GrSWMaskHelper.h
+++ b/src/gpu/GrSWMaskHelper.h
@@ -19,6 +19,7 @@
#include "SkTypes.h"
class GrClip;
+class GrShape;
class GrTextureProvider;
class GrTexture;
class SkPath;
@@ -52,8 +53,7 @@ public:
void drawRect(const SkRect& rect, SkRegion::Op op, bool antiAlias, uint8_t alpha);
// Draw a single path into the accumuation bitmap using the specified op
- void drawPath(const SkPath& path, const GrStyle& style, SkRegion::Op op,
- bool antiAlias, uint8_t alpha);
+ void drawShape(const GrShape&, SkRegion::Op op, bool antiAlias, uint8_t alpha);
// Move the mask generation results from the internal bitmap to the gpu.
void toTexture(GrTexture* texture);
@@ -68,14 +68,13 @@ public:
// Canonical usage utility that draws a single path and uploads it
// to the GPU. The result is returned.
- static GrTexture* DrawPathMaskToTexture(GrTextureProvider*,
- const SkPath& path,
- const GrStyle& style,
- const SkIRect& resultBounds,
- bool antiAlias,
- const SkMatrix* matrix);
-
- // This utility routine is used to add a path's mask to some other draw.
+ static GrTexture* DrawShapeMaskToTexture(GrTextureProvider*,
+ const GrShape&,
+ const SkIRect& resultBounds,
+ bool antiAlias,
+ const SkMatrix* matrix);
+
+ // This utility routine is used to add a shape's mask to some other draw.
// The ClipMaskManager uses it to accumulate clip masks while the
// GrSoftwarePathRenderer uses it to fulfill a drawPath call.
// It draws with "texture" as a path mask into "target" using "rect" as
@@ -85,14 +84,14 @@ public:
// the draw state can be used to hold the mask texture stage.
// This method is really only intended to be used with the
// output of DrawPathMaskToTexture.
- static void DrawToTargetWithPathMask(GrTexture* texture,
- GrDrawContext*,
- const GrPaint* paint,
- const GrUserStencilSettings* userStencilSettings,
- const GrClip&,
- GrColor,
- const SkMatrix& viewMatrix,
- const SkIRect& rect);
+ static void DrawToTargetWithShapeMask(GrTexture* texture,
+ GrDrawContext*,
+ const GrPaint* paint,
+ const GrUserStencilSettings* userStencilSettings,
+ const GrClip&,
+ GrColor,
+ const SkMatrix& viewMatrix,
+ const SkIRect& rect);
private:
// Helper function to get a scratch texture suitable for capturing the
« no previous file with comments | « src/gpu/GrPathRendererChain.cpp ('k') | src/gpu/GrSWMaskHelper.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698