diff options
author | Robert Phillips <robertphillips@google.com> | 2018-06-14 14:31:17 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-06-15 11:33:14 +0000 |
commit | c8cee446bf9c07da8848bbd032abf26e79966ac1 (patch) | |
tree | 5f024f9dfb1aca470915da9fae96eac0710f5884 /src/gpu/GrOpList.cpp | |
parent | 9e6402677f1c8f2c3bdc3b812ee38ea2931d92b3 (diff) |
Move op memory storage to GrContext
TBR=bsalomon@google.com
Change-Id: Ifa95bf0073b9d948f2c937d10088b7734b971f90
Reviewed-on: https://skia-review.googlesource.com/131500
Reviewed-by: Brian Salomon <bsalomon@google.com>
Reviewed-by: Greg Daniel <egdaniel@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
Diffstat (limited to 'src/gpu/GrOpList.cpp')
-rw-r--r-- | src/gpu/GrOpList.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/src/gpu/GrOpList.cpp b/src/gpu/GrOpList.cpp index 6fed34a38c..b9f425576e 100644 --- a/src/gpu/GrOpList.cpp +++ b/src/gpu/GrOpList.cpp @@ -9,6 +9,7 @@ #include "GrContext.h" #include "GrDeferredProxyUploader.h" +#include "GrMemoryPool.h" #include "GrSurfaceProxy.h" #include "GrTextureProxyPriv.h" @@ -24,11 +25,13 @@ uint32_t GrOpList::CreateUniqueID() { return id; } -GrOpList::GrOpList(GrResourceProvider* resourceProvider, +GrOpList::GrOpList(GrResourceProvider* resourceProvider, sk_sp<GrOpMemoryPool> opMemoryPool, GrSurfaceProxy* surfaceProxy, GrAuditTrail* auditTrail) - : fAuditTrail(auditTrail) - , fUniqueID(CreateUniqueID()) - , fFlags(0) { + : fOpMemoryPool(std::move(opMemoryPool)) + , fAuditTrail(auditTrail) + , fUniqueID(CreateUniqueID()) + , fFlags(0) { + SkASSERT(fOpMemoryPool); fTarget.setProxy(sk_ref_sp(surfaceProxy), kWrite_GrIOType); fTarget.get()->setLastOpList(this); |