Make GrGpuCommandBuffer infer its render target from first draw
This is a temporary workaround to allow removal of GrBatch::renderTarget().
Change-Id: Ic14710a369802064cf6446e8191a98ea3595556d
Reviewed-on: https://skia-review.googlesource.com/5342
Commit-Queue: Brian Salomon <bsalomon@google.com>
Reviewed-by: Robert Phillips <robertphillips@google.com>
diff --git a/src/gpu/GrRenderTargetOpList.cpp b/src/gpu/GrRenderTargetOpList.cpp
index aab71f9..b69d915 100644
--- a/src/gpu/GrRenderTargetOpList.cpp
+++ b/src/gpu/GrRenderTargetOpList.cpp
@@ -204,8 +204,7 @@
static const GrGpuCommandBuffer::LoadAndStoreInfo kBasicLoadStoreInfo
{ GrGpuCommandBuffer::LoadOp::kLoad,GrGpuCommandBuffer::StoreOp::kStore,
GrColor_ILLEGAL };
- commandBuffer.reset(fGpu->createCommandBuffer(currentRT,
- kBasicLoadStoreInfo, // Color
+ commandBuffer.reset(fGpu->createCommandBuffer(kBasicLoadStoreInfo, // Color
kBasicLoadStoreInfo)); // Stencil
}
flushState->setCommandBuffer(commandBuffer.get());