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/ResourceCacheTest.cpp b/tests/ResourceCacheTest.cpp
index 27d1971..96cda79 100644
--- a/tests/ResourceCacheTest.cpp
+++ b/tests/ResourceCacheTest.cpp
@@ -16,6 +16,7 @@
#include "GrGpu.h"
#include "GrGpuResourceCacheAccess.h"
#include "GrGpuResourcePriv.h"
+#include "GrProxyProvider.h"
#include "GrRenderTargetPriv.h"
#include "GrResourceCache.h"
#include "GrResourceProvider.h"
@@ -1632,7 +1633,7 @@
return provider->createTexture(desc, SkBudgeted::kYes);
}
-static sk_sp<GrTextureProxy> make_mipmap_proxy(GrProxyProvider* provider,
+static sk_sp<GrTextureProxy> make_mipmap_proxy(GrProxyProvider* proxyProvider,
GrSurfaceFlags flags,
int width, int height,
int sampleCnt) {
@@ -1668,8 +1669,7 @@
desc.fConfig = kRGBA_8888_GrPixelConfig;
desc.fSampleCnt = sampleCnt;
- return GrSurfaceProxy::MakeDeferredMipMap(provider, desc, SkBudgeted::kYes,
- texels.get(), mipLevelCount);
+ return proxyProvider->createMipMapProxy(desc, SkBudgeted::kYes, texels.get(), mipLevelCount);
}
// Exercise GrSurface::gpuMemorySize for different combos of MSAA, RT-only,