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

Unified Diff: src/gpu/GrResourceProvider.h

Issue 1155593002: Move GrPath(Range) creation to ResourceProvider. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 5 years, 7 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/GrAddPathRenderers_default.cpp ('k') | src/gpu/GrResourceProvider.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/gpu/GrResourceProvider.h
diff --git a/src/gpu/GrResourceProvider.h b/src/gpu/GrResourceProvider.h
index 0d80cdd2a086f45941aba8c838ef9d7cc49de8fe..12e6c559852d4bdd0d8027e1815c7a73874514ad 100644
--- a/src/gpu/GrResourceProvider.h
+++ b/src/gpu/GrResourceProvider.h
@@ -9,9 +9,15 @@
#define GrResourceProvider_DEFINED
#include "GrTextureProvider.h"
+#include "GrPathRange.h"
class GrIndexBuffer;
+class GrPath;
+class GrStrokeInfo;
class GrVertexBuffer;
+class SkDescriptor;
+class SkPath;
+class SkTypeface;
/**
* An extension of the texture provider for arbitrary resource types. This class is intended for
@@ -66,6 +72,14 @@ public:
return this->createQuadIndexBuffer();
}
+ /**
+ * Factories for GrPath and GrPathRange objects. It's an error to call these if path rendering
+ * is not supported.
+ */
+ GrPath* createPath(const SkPath&, const GrStrokeInfo&);
+ GrPathRange* createPathRange(GrPathRange::PathGenerator*, const GrStrokeInfo&);
+ GrPathRange* createGlyphs(const SkTypeface*, const SkDescriptor*, const GrStrokeInfo&);
+
using GrTextureProvider::assignUniqueKeyToResource;
using GrTextureProvider::findAndRefResourceByUniqueKey;
« no previous file with comments | « src/gpu/GrAddPathRenderers_default.cpp ('k') | src/gpu/GrResourceProvider.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698