Rename GrSurfaceDrawContext to skgpu::v1::SurfaceDrawContext

This CL is mostly mechanical. It:

replaces "src/gpu/GrSurfaceDrawContext.h" #includes with
         "src/gpu/v1/SurfaceDrawContext_v1.h" and reorders

replaces "class GrSurfaceDrawContext;" with
         "namespace skgpu { namespace v1 { class SurfaceDrawContext; }}"

replaces "GrSurfaceDrawContext*" with "auto" where possible
replaces "rtc" with "sdc"
replaces "surfaceDrawContext" with "sdc"
replaces GrSurfaceDrawContext with skgpu::v1::SurfaceDrawContext
reflows parameters as needed

This CL does not try to:

make skgpu::v1::SurfaceDrawContext V1-only
minimize the skgpu and/or skgpu::v1 prefixes

Those two tasks will be accomplished in follow up CLs. This CL is just trying to get the bulk of the mechanical changes comprehensibly landed.

Bug: skia:11837
Change-Id: I6fe59080249d585df8f5d27c6b67569cdc35842f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/433156
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
diff --git a/src/gpu/GrSoftwarePathRenderer.cpp b/src/gpu/GrSoftwarePathRenderer.cpp
index bd96e59..b32dbe5 100644
--- a/src/gpu/GrSoftwarePathRenderer.cpp
+++ b/src/gpu/GrSoftwarePathRenderer.cpp
@@ -21,12 +21,12 @@
 #include "src/gpu/GrProxyProvider.h"
 #include "src/gpu/GrRecordingContextPriv.h"
 #include "src/gpu/GrSWMaskHelper.h"
-#include "src/gpu/GrSurfaceDrawContext.h"
 #include "src/gpu/GrUtil.h"
 #include "src/gpu/SkGr.h"
 #include "src/gpu/effects/GrTextureEffect.h"
 #include "src/gpu/geometry/GrStyledShape.h"
 #include "src/gpu/ops/GrDrawOp.h"
+#include "src/gpu/v1/SurfaceDrawContext_v1.h"
 
 ////////////////////////////////////////////////////////////////////////////////
 GrPathRenderer::CanDrawPath
@@ -69,7 +69,7 @@
 
 // Gets the shape bounds, the clip bounds, and the intersection (if any). Returns false if there
 // is no intersection.
-bool GrSoftwarePathRenderer::GetShapeAndClipBounds(GrSurfaceDrawContext* surfaceDrawContext,
+bool GrSoftwarePathRenderer::GetShapeAndClipBounds(skgpu::v1::SurfaceDrawContext* sdc,
                                                    const GrClip* clip,
                                                    const GrStyledShape& shape,
                                                    const SkMatrix& matrix,
@@ -78,8 +78,7 @@
                                                    SkIRect* devClipBounds) {
     // compute bounds as intersection of rt size, clip, and path
     *devClipBounds = clip ? clip->getConservativeBounds()
-                          : SkIRect::MakeWH(surfaceDrawContext->width(),
-                                            surfaceDrawContext->height());
+                          : SkIRect::MakeWH(sdc->width(), sdc->height());
 
     if (!get_unclipped_shape_dev_bounds(shape, matrix, unclippedDevShapeBounds)) {
         *unclippedDevShapeBounds = SkIRect::MakeEmpty();
@@ -95,18 +94,18 @@
 
 ////////////////////////////////////////////////////////////////////////////////
 
-void GrSoftwarePathRenderer::DrawNonAARect(GrSurfaceDrawContext* surfaceDrawContext,
+void GrSoftwarePathRenderer::DrawNonAARect(skgpu::v1::SurfaceDrawContext* sdc,
                                            GrPaint&& paint,
                                            const GrUserStencilSettings& userStencilSettings,
                                            const GrClip* clip,
                                            const SkMatrix& viewMatrix,
                                            const SkRect& rect,
                                            const SkMatrix& localMatrix) {
-    surfaceDrawContext->stencilRect(clip, &userStencilSettings, std::move(paint), GrAA::kNo,
-                                    viewMatrix, rect, &localMatrix);
+    sdc->stencilRect(clip, &userStencilSettings, std::move(paint), GrAA::kNo,
+                     viewMatrix, rect, &localMatrix);
 }
 
-void GrSoftwarePathRenderer::DrawAroundInvPath(GrSurfaceDrawContext* surfaceDrawContext,
+void GrSoftwarePathRenderer::DrawAroundInvPath(skgpu::v1::SurfaceDrawContext* sdc,
                                                GrPaint&& paint,
                                                const GrUserStencilSettings& userStencilSettings,
                                                const GrClip* clip,
@@ -122,32 +121,32 @@
     if (devClipBounds.fTop < devPathBounds.fTop) {
         rect.setLTRB(SkIntToScalar(devClipBounds.fLeft),  SkIntToScalar(devClipBounds.fTop),
                      SkIntToScalar(devClipBounds.fRight), SkIntToScalar(devPathBounds.fTop));
-        DrawNonAARect(surfaceDrawContext, GrPaint::Clone(paint), userStencilSettings, clip,
+        DrawNonAARect(sdc, GrPaint::Clone(paint), userStencilSettings, clip,
                       SkMatrix::I(), rect, invert);
     }
     if (devClipBounds.fLeft < devPathBounds.fLeft) {
         rect.setLTRB(SkIntToScalar(devClipBounds.fLeft), SkIntToScalar(devPathBounds.fTop),
                      SkIntToScalar(devPathBounds.fLeft), SkIntToScalar(devPathBounds.fBottom));
-        DrawNonAARect(surfaceDrawContext, GrPaint::Clone(paint), userStencilSettings, clip,
+        DrawNonAARect(sdc, GrPaint::Clone(paint), userStencilSettings, clip,
                       SkMatrix::I(), rect, invert);
     }
     if (devClipBounds.fRight > devPathBounds.fRight) {
         rect.setLTRB(SkIntToScalar(devPathBounds.fRight), SkIntToScalar(devPathBounds.fTop),
                      SkIntToScalar(devClipBounds.fRight), SkIntToScalar(devPathBounds.fBottom));
-        DrawNonAARect(surfaceDrawContext, GrPaint::Clone(paint), userStencilSettings, clip,
+        DrawNonAARect(sdc, GrPaint::Clone(paint), userStencilSettings, clip,
                       SkMatrix::I(), rect, invert);
     }
     if (devClipBounds.fBottom > devPathBounds.fBottom) {
         rect.setLTRB(SkIntToScalar(devClipBounds.fLeft),  SkIntToScalar(devPathBounds.fBottom),
                      SkIntToScalar(devClipBounds.fRight), SkIntToScalar(devClipBounds.fBottom));
-        DrawNonAARect(surfaceDrawContext, std::move(paint), userStencilSettings, clip,
+        DrawNonAARect(sdc, std::move(paint), userStencilSettings, clip,
                       SkMatrix::I(), rect, invert);
     }
 }
 
 void GrSoftwarePathRenderer::DrawToTargetWithShapeMask(
         GrSurfaceProxyView view,
-        GrSurfaceDrawContext* surfaceDrawContext,
+        skgpu::v1::SurfaceDrawContext* sdc,
         GrPaint&& paint,
         const GrUserStencilSettings& userStencilSettings,
         const GrClip* clip,
@@ -172,7 +171,7 @@
 
     paint.setCoverageFragmentProcessor(GrTextureEffect::Make(
             std::move(view), kPremul_SkAlphaType, maskMatrix, GrSamplerState::Filter::kNearest));
-    DrawNonAARect(surfaceDrawContext, std::move(paint), userStencilSettings, clip, SkMatrix::I(),
+    DrawNonAARect(sdc, std::move(paint), userStencilSettings, clip, SkMatrix::I(),
                   dstRect, invert);
 }