Index: include/gpu/GrContext.h |
diff --git a/include/gpu/GrContext.h b/include/gpu/GrContext.h |
index 7716f9ae7c71c1fcea09d88772adfd578e5ab262..4fc4cf7254e6907538b37c7165dfc5d0df494131 100644 |
--- a/include/gpu/GrContext.h |
+++ b/include/gpu/GrContext.h |
@@ -29,6 +29,7 @@ class GrIndexBuffer; |
class GrIndexBufferAllocPool; |
class GrInOrderDrawBuffer; |
class GrOvalRenderer; |
+class GrPath; |
class GrPathRenderer; |
class GrResourceEntry; |
class GrResourceCache; |
@@ -263,6 +264,17 @@ public: |
*/ |
void setMaxTextureSizeOverride(int maxTextureSizeOverride); |
+ // Other resources |
+ |
+ /** Creates a new gpu path, based on the specified path and stroke and returns it. |
+ * The caller owns a ref on the returned path which must be balanced by a call to unref. |
+ * |
+ * @param skPath the path geometry. |
+ * @param stroke the path stroke. |
+ * @return a new path or NULL if the operation is not supported by the backend. |
+ */ |
+ GrPath* createPath(const SkPath& skPath, const SkStrokeRec& stroke); |
bsalomon
2013/10/18 13:25:24
I'm wondering if there is any way to avoid this as
Kimmo Kinnunen
2013/10/21 13:40:48
Done.
|
+ |
/////////////////////////////////////////////////////////////////////////// |
// Render targets |
@@ -868,6 +880,7 @@ private: |
GrDrawState* fDrawState; |
GrResourceCache* fTextureCache; |
+ GrResourceCache* fPathCache; // TODO: merge this with fTextureCache. |
GrFontCache* fFontCache; |
GrPathRendererChain* fPathRendererChain; |