switch surface to sk_sp
BUG=skia:
GOLD_TRYBOT_URL= https://gold.skia.org/search2?unt=true&query=source_type%3Dgm&master=false&issue=1817383002
CQ_EXTRA_TRYBOTS=client.skia.compile:Build-Ubuntu-GCC-x86_64-Release-CMake-Trybot,Build-Mac-Clang-x86_64-Release-CMake-Trybot
Review URL: https://codereview.chromium.org/1817383002
diff --git a/src/image/SkSurface.cpp b/src/image/SkSurface.cpp
index bb807ba..b3a65fa 100644
--- a/src/image/SkSurface.cpp
+++ b/src/image/SkSurface.cpp
@@ -172,7 +172,7 @@
return asSB(this)->refCachedImage(budgeted, unique);
}
-SkSurface* SkSurface::newSurface(const SkImageInfo& info) {
+sk_sp<SkSurface> SkSurface::makeSurface(const SkImageInfo& info) {
return asSB(this)->onNewSurface(info);
}
@@ -222,27 +222,28 @@
#if !SK_SUPPORT_GPU
-SkSurface* SkSurface::NewRenderTargetDirect(GrRenderTarget*, const SkSurfaceProps*) {
+sk_sp<SkSurface> SkSurface::MakeRenderTargetDirect(GrRenderTarget*, const SkSurfaceProps*) {
return nullptr;
}
-SkSurface* SkSurface::NewRenderTarget(GrContext*, SkBudgeted, const SkImageInfo&, int,
- const SkSurfaceProps*, GrTextureStorageAllocator) {
+sk_sp<SkSurface> SkSurface::MakeRenderTarget(GrContext*, SkBudgeted, const SkImageInfo&, int,
+ const SkSurfaceProps*, GrTextureStorageAllocator) {
return nullptr;
}
-SkSurface* SkSurface::NewFromBackendTexture(GrContext*, const GrBackendTextureDesc&,
- const SkSurfaceProps*) {
+sk_sp<SkSurface> SkSurface::MakeFromBackendTexture(GrContext*, const GrBackendTextureDesc&,
+ const SkSurfaceProps*) {
return nullptr;
}
-SkSurface* SkSurface::NewFromBackendRenderTarget(GrContext*, const GrBackendRenderTargetDesc&,
- const SkSurfaceProps*) {
+sk_sp<SkSurface> SkSurface::MakeFromBackendRenderTarget(GrContext*,
+ const GrBackendRenderTargetDesc&,
+ const SkSurfaceProps*) {
return nullptr;
}
-SkSurface* NewFromBackendTextureAsRenderTarget(GrContext*, const GrBackendTextureDesc&,
- const SkSurfaceProps*) {
+sk_sp<SkSurface> MakeFromBackendTextureAsRenderTarget(GrContext*, const GrBackendTextureDesc&,
+ const SkSurfaceProps*) {
return nullptr;
}