Revert "Store GrSwizzle on proxies for texturing and swizzling."
This reverts commit 23093135d17427ef59385761d2d729ada6d961cf.
Reason for revert: Breaking Google3 :(
Original change's description:
> Store GrSwizzle on proxies for texturing and swizzling.
>
> Bug: skia: 6718
> Change-Id: I023d7507da9334e984ac8209a32323d616b3d79d
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/214305
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Greg Daniel <egdaniel@google.com>
TBR=egdaniel@google.com,bsalomon@google.com,robertphillips@google.com
Change-Id: Ie2303ad090f58de07db7b0ac2d42e06e5e5bbcc1
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia: 6718
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/221338
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
diff --git a/src/gpu/GrRenderTargetProxy.cpp b/src/gpu/GrRenderTargetProxy.cpp
index c90ff98..bd453c8 100644
--- a/src/gpu/GrRenderTargetProxy.cpp
+++ b/src/gpu/GrRenderTargetProxy.cpp
@@ -21,12 +21,10 @@
// cases to make the sampleConfig/numSamples stuff more rational.
GrRenderTargetProxy::GrRenderTargetProxy(const GrCaps& caps, const GrBackendFormat& format,
const GrSurfaceDesc& desc, GrSurfaceOrigin origin,
- const GrSwizzle& textureSwizzle,
- const GrSwizzle& outputSwizzle, SkBackingFit fit,
- SkBudgeted budgeted, GrInternalSurfaceFlags surfaceFlags)
- : INHERITED(format, desc, origin, textureSwizzle, fit, budgeted, surfaceFlags)
+ SkBackingFit fit, SkBudgeted budgeted,
+ GrInternalSurfaceFlags surfaceFlags)
+ : INHERITED(format, desc, origin, fit, budgeted, surfaceFlags)
, fSampleCnt(desc.fSampleCnt)
- , fOutputSwizzle(outputSwizzle)
, fNeedsStencil(false)
, fWrapsVkSecondaryCB(WrapsVkSecondaryCB::kNo) {
// Since we know the newly created render target will be internal, we are able to precompute
@@ -40,14 +38,12 @@
GrRenderTargetProxy::GrRenderTargetProxy(LazyInstantiateCallback&& callback,
LazyInstantiationType lazyType,
const GrBackendFormat& format, const GrSurfaceDesc& desc,
- GrSurfaceOrigin origin, const GrSwizzle& textureSwizzle,
- const GrSwizzle& outputSwizzle, SkBackingFit fit,
+ GrSurfaceOrigin origin, SkBackingFit fit,
SkBudgeted budgeted, GrInternalSurfaceFlags surfaceFlags,
WrapsVkSecondaryCB wrapsVkSecondaryCB)
- : INHERITED(std::move(callback), lazyType, format, desc, origin, textureSwizzle, fit,
- budgeted, surfaceFlags)
+ : INHERITED(std::move(callback), lazyType, format, desc, origin, fit, budgeted,
+ surfaceFlags)
, fSampleCnt(desc.fSampleCnt)
- , fOutputSwizzle(outputSwizzle)
, fNeedsStencil(false)
, fWrapsVkSecondaryCB(wrapsVkSecondaryCB) {
SkASSERT(SkToBool(kRenderTarget_GrSurfaceFlag & desc.fFlags));
@@ -55,12 +51,9 @@
// Wrapped version
GrRenderTargetProxy::GrRenderTargetProxy(sk_sp<GrSurface> surf, GrSurfaceOrigin origin,
- const GrSwizzle& textureSwizzle,
- const GrSwizzle& outputSwizzle,
WrapsVkSecondaryCB wrapsVkSecondaryCB)
- : INHERITED(std::move(surf), origin, textureSwizzle, SkBackingFit::kExact)
+ : INHERITED(std::move(surf), origin, SkBackingFit::kExact)
, fSampleCnt(fTarget->asRenderTarget()->numStencilSamples())
- , fOutputSwizzle(outputSwizzle)
, fNeedsStencil(false)
, fWrapsVkSecondaryCB(wrapsVkSecondaryCB) {
}