aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/gpu
diff options
context:
space:
mode:
authorGravatar Brian Salomon <bsalomon@google.com>2017-01-11 13:42:54 -0500
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-01-11 19:56:48 +0000
commit82f44319159bb98dcacdbbec7ea643dde5ed024b (patch)
treedcd8c8a5caaac2675fcfdf48c5af67f946200c24 /tools/gpu
parentab273facbfe496a3d5dd798e6b4b57c41eed7f16 (diff)
Make GrPaints move their GrProcessor ownership into GrPipelineBuilder.
This makes GrPaints usable only once. In some places we must make copies in order to issue draws with the same paint state. Change-Id: Ie816e5185ce93a064111cad64c6880e1e21184c2 Reviewed-on: https://skia-review.googlesource.com/6844 Reviewed-by: Robert Phillips <robertphillips@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'tools/gpu')
-rw-r--r--tools/gpu/GrTest.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/gpu/GrTest.cpp b/tools/gpu/GrTest.cpp
index 95ee6b8ab2..b1c179b32a 100644
--- a/tools/gpu/GrTest.cpp
+++ b/tools/gpu/GrTest.cpp
@@ -241,7 +241,7 @@ int GrResourceCache::countUniqueKeysWithTag(const char* tag) const {
SkDEBUGCODE(GrSingleOwner::AutoEnforce debug_SingleOwner(fRenderTargetContext->fSingleOwner);)
#define RETURN_IF_ABANDONED if (fRenderTargetContext->fDrawingManager->wasAbandoned()) { return; }
-void GrRenderTargetContextPriv::testingOnly_addDrawOp(const GrPaint& paint,
+void GrRenderTargetContextPriv::testingOnly_addDrawOp(GrPaint&& paint,
GrAAType aaType,
std::unique_ptr<GrDrawOp>
op,
@@ -253,7 +253,7 @@ void GrRenderTargetContextPriv::testingOnly_addDrawOp(const GrPaint& paint,
GR_AUDIT_TRAIL_AUTO_FRAME(fRenderTargetContext->fAuditTrail,
"GrRenderTargetContext::testingOnly_addDrawOp");
- GrPipelineBuilder pipelineBuilder(paint, aaType);
+ GrPipelineBuilder pipelineBuilder(std::move(paint), aaType);
if (uss) {
pipelineBuilder.setUserStencil(uss);
}