diff options
author | Greg Daniel <egdaniel@google.com> | 2018-01-10 17:06:31 -0500 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-01-12 19:36:08 +0000 |
commit | 65fa8ca85ef146340ddea61bb08c182df499ca62 (patch) | |
tree | c8795e3ecf0c2c45929249b03dcbe108f52e2445 /src/gpu/GrRenderTargetProxy.cpp | |
parent | e2330261a704e2db762e2de0d297bf8b4dc510f1 (diff) |
Updating lazy proxys to support the case where we know a lot more info about the texture.
This is needed for future DDL texture work.
Bug: skia:
Change-Id: I07e0b9c67509e63b9cac00adc355254d03784df8
Reviewed-on: https://skia-review.googlesource.com/91500
Commit-Queue: Greg Daniel <egdaniel@google.com>
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Diffstat (limited to 'src/gpu/GrRenderTargetProxy.cpp')
-rw-r--r-- | src/gpu/GrRenderTargetProxy.cpp | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/gpu/GrRenderTargetProxy.cpp b/src/gpu/GrRenderTargetProxy.cpp index dea47e6b5c..d1b77d2354 100644 --- a/src/gpu/GrRenderTargetProxy.cpp +++ b/src/gpu/GrRenderTargetProxy.cpp @@ -35,11 +35,15 @@ GrRenderTargetProxy::GrRenderTargetProxy(const GrCaps& caps, const GrSurfaceDesc } // Lazy-callback version -GrRenderTargetProxy::GrRenderTargetProxy(LazyInstantiateCallback&& callback, GrPixelConfig config) - : INHERITED(std::move(callback), config) - , fSampleCnt(0) +GrRenderTargetProxy::GrRenderTargetProxy(LazyInstantiateCallback&& callback, + const GrSurfaceDesc& desc, + SkBackingFit fit, SkBudgeted budgeted, + uint32_t flags) + : INHERITED(std::move(callback), desc, fit, budgeted, flags) + , fSampleCnt(desc.fSampleCnt) , fNeedsStencil(false) , fRenderTargetFlags(GrRenderTargetFlags::kNone) { + SkASSERT(SkToBool(kRenderTarget_GrSurfaceFlag & desc.fFlags)); } // Wrapped version |