Switch path renderers over to using GrRecordingContext

The path renderers convert paths into Ganesh ops when recording so should also be able to make due with only the GrRecordingContext.

Change-Id: Ie796af73ca5aa2a074ebd037d6d558ec85ff5928
Reviewed-on: https://skia-review.googlesource.com/c/191568
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
diff --git a/src/gpu/ccpr/GrCCDrawPathsOp.cpp b/src/gpu/ccpr/GrCCDrawPathsOp.cpp
index 643118a..79e318f 100644
--- a/src/gpu/ccpr/GrCCDrawPathsOp.cpp
+++ b/src/gpu/ccpr/GrCCDrawPathsOp.cpp
@@ -7,10 +7,10 @@
 
 #include "GrCCDrawPathsOp.h"
 
-#include "GrContext.h"
-#include "GrContextPriv.h"
 #include "GrMemoryPool.h"
 #include "GrOpFlushState.h"
+#include "GrRecordingContext.h"
+#include "GrRecordingContextPriv.h"
 #include "ccpr/GrCCPathCache.h"
 #include "ccpr/GrCCPerFlushResources.h"
 #include "ccpr/GrCoverageCountingPathRenderer.h"
@@ -26,8 +26,8 @@
 }
 
 std::unique_ptr<GrCCDrawPathsOp> GrCCDrawPathsOp::Make(
-        GrContext* context, const SkIRect& clipIBounds, const SkMatrix& m, const GrShape& shape,
-        GrPaint&& paint) {
+        GrRecordingContext* context, const SkIRect& clipIBounds, const SkMatrix& m,
+        const GrShape& shape, GrPaint&& paint) {
     SkRect conservativeDevBounds;
     m.mapRect(&conservativeDevBounds, shape.bounds());
 
@@ -75,8 +75,9 @@
 }
 
 std::unique_ptr<GrCCDrawPathsOp> GrCCDrawPathsOp::InternalMake(
-        GrContext* context, const SkIRect& clipIBounds, const SkMatrix& m, const GrShape& shape,
-        float strokeDevWidth, const SkRect& conservativeDevBounds, GrPaint&& paint) {
+        GrRecordingContext* context, const SkIRect& clipIBounds, const SkMatrix& m,
+        const GrShape& shape, float strokeDevWidth, const SkRect& conservativeDevBounds,
+        GrPaint&& paint) {
     // The path itself should have been cropped if larger than kPathCropThreshold. If it had a
     // stroke, that would have further inflated its draw bounds.
     SkASSERT(SkTMax(conservativeDevBounds.height(), conservativeDevBounds.width()) <
diff --git a/src/gpu/ccpr/GrCCDrawPathsOp.h b/src/gpu/ccpr/GrCCDrawPathsOp.h
index fef4ead..1ab180a 100644
--- a/src/gpu/ccpr/GrCCDrawPathsOp.h
+++ b/src/gpu/ccpr/GrCCDrawPathsOp.h
@@ -14,11 +14,12 @@
 #include "ccpr/GrCCPathCache.h"
 #include "ops/GrDrawOp.h"
 
+class GrCCAtlas;
+class GrCCPerFlushResources;
 struct GrCCPerFlushResourceSpecs;
 struct GrCCPerOpListPaths;
-class GrCCAtlas;
 class GrOnFlushResourceProvider;
-class GrCCPerFlushResources;
+class GrRecordingContext;
 
 /**
  * This is the Op that draws paths to the actual canvas, using atlases generated by CCPR.
@@ -28,7 +29,7 @@
     DEFINE_OP_CLASS_ID
     SK_DECLARE_INTERNAL_LLIST_INTERFACE(GrCCDrawPathsOp);
 
-    static std::unique_ptr<GrCCDrawPathsOp> Make(GrContext*, const SkIRect& clipIBounds,
+    static std::unique_ptr<GrCCDrawPathsOp> Make(GrRecordingContext*, const SkIRect& clipIBounds,
                                                  const SkMatrix&, const GrShape&, GrPaint&&);
     ~GrCCDrawPathsOp() override;
 
@@ -68,7 +69,8 @@
 private:
     friend class GrOpMemoryPool;
 
-    static std::unique_ptr<GrCCDrawPathsOp> InternalMake(GrContext*, const SkIRect& clipIBounds,
+    static std::unique_ptr<GrCCDrawPathsOp> InternalMake(GrRecordingContext*,
+                                                         const SkIRect& clipIBounds,
                                                          const SkMatrix&, const GrShape&,
                                                          float strokeDevWidth,
                                                          const SkRect& conservativeDevBounds,