Funnel most proxy creation through GrProxyProvider
This is to provide a choke point for DDL to create Lazy Proxies.
Change-Id: If178da13bc6447b31b7601810236d34502d9efbd
Reviewed-on: https://skia-review.googlesource.com/93303
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
diff --git a/tests/CopySurfaceTest.cpp b/tests/CopySurfaceTest.cpp
index 0d9fc86..1c31bbf 100644
--- a/tests/CopySurfaceTest.cpp
+++ b/tests/CopySurfaceTest.cpp
@@ -11,6 +11,7 @@
#if SK_SUPPORT_GPU
#include "GrContext.h"
#include "GrContextPriv.h"
+#include "GrProxyProvider.h"
#include "GrResourceProvider.h"
#include "GrSurfaceContext.h"
#include "GrSurfaceProxy.h"
@@ -74,17 +75,10 @@
dstDesc.fOrigin = dOrigin;
dstDesc.fFlags = dFlags;
- sk_sp<GrTextureProxy> src(GrSurfaceProxy::MakeDeferred(
- proxyProvider,
- srcDesc, SkBudgeted::kNo,
- srcPixels.get(),
- kRowBytes));
-
- sk_sp<GrTextureProxy> dst(GrSurfaceProxy::MakeDeferred(
- proxyProvider,
- dstDesc, SkBudgeted::kNo,
- dstPixels.get(),
- kRowBytes));
+ sk_sp<GrTextureProxy> src = proxyProvider->createTextureProxy(
+ srcDesc, SkBudgeted::kNo, srcPixels.get(), kRowBytes);
+ sk_sp<GrTextureProxy> dst = proxyProvider->createTextureProxy(
+ dstDesc, SkBudgeted::kNo, dstPixels.get(), kRowBytes);
if (!src || !dst) {
ERRORF(reporter,
"Could not create surfaces for copy surface test.");