No longer forward refs and unrefs from the GrSurfaceProxy to the backing GrSurface
This is setting up for GrIORefProxy to just become SkRefCnt and GrProxyRef to just become sk_sp.
Change-Id: Ica66565a353de980a7070e0788f1f2b17565baee
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/220297
Commit-Queue: Robert Phillips <robertphillips@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
diff --git a/src/gpu/GrResourceAllocator.cpp b/src/gpu/GrResourceAllocator.cpp
index d37d81c..82c8b82 100644
--- a/src/gpu/GrResourceAllocator.cpp
+++ b/src/gpu/GrResourceAllocator.cpp
@@ -44,10 +44,10 @@
continue;
}
- if (cur->uses() >= cur->proxy()->priv().getTotalRefs()) {
+ if (cur->uses() >= cur->proxy()->priv().getProxyRefCnt()) {
// All the refs on the proxy are known to the resource allocator thus no one
// should be holding onto it outside of Ganesh.
- SkASSERT(cur->uses() == cur->proxy()->priv().getTotalRefs());
+ SkASSERT(cur->uses() == cur->proxy()->priv().getProxyRefCnt());
cur->markAsRecyclable();
}
}