aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/gpu/GrSoftwarePathRenderer.cpp
diff options
context:
space:
mode:
authorGravatar Brian Salomon <bsalomon@google.com>2017-08-10 12:46:01 -0400
committerGravatar Skia Commit-Bot <skia-commit-bot@chromium.org>2017-08-10 17:56:45 +0000
commitb74ef035a42af8acf028abd129cb59862cb15c46 (patch)
tree97fb33acaf4a60747675a8084ab027dd61bf8f05 /src/gpu/GrSoftwarePathRenderer.cpp
parent92e6cc6b2d42f3826b36bd24da7dd3fe8443b114 (diff)
Hide GrPaint copy constructor and add GrPaint::Clone and remove MoveOrNew and MoveOrCopy.
Also makes paint clones use cloned fragment processors. Change-Id: I60efcfc6a46a4f8430a72f4d1ec79c7d99fbe593 Reviewed-on: https://skia-review.googlesource.com/33084 Reviewed-by: Brian Osman <brianosman@google.com> Commit-Queue: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'src/gpu/GrSoftwarePathRenderer.cpp')
-rw-r--r--src/gpu/GrSoftwarePathRenderer.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/gpu/GrSoftwarePathRenderer.cpp b/src/gpu/GrSoftwarePathRenderer.cpp
index f479a483fe..8858bf90a2 100644
--- a/src/gpu/GrSoftwarePathRenderer.cpp
+++ b/src/gpu/GrSoftwarePathRenderer.cpp
@@ -98,20 +98,20 @@ void GrSoftwarePathRenderer::DrawAroundInvPath(GrRenderTargetContext* renderTarg
if (devClipBounds.fTop < devPathBounds.fTop) {
rect.iset(devClipBounds.fLeft, devClipBounds.fTop,
devClipBounds.fRight, devPathBounds.fTop);
- DrawNonAARect(renderTargetContext, GrPaint(paint), userStencilSettings, clip, SkMatrix::I(),
- rect, invert);
+ DrawNonAARect(renderTargetContext, GrPaint::Clone(paint), userStencilSettings, clip,
+ SkMatrix::I(), rect, invert);
}
if (devClipBounds.fLeft < devPathBounds.fLeft) {
rect.iset(devClipBounds.fLeft, devPathBounds.fTop,
devPathBounds.fLeft, devPathBounds.fBottom);
- DrawNonAARect(renderTargetContext, GrPaint(paint), userStencilSettings, clip, SkMatrix::I(),
- rect, invert);
+ DrawNonAARect(renderTargetContext, GrPaint::Clone(paint), userStencilSettings, clip,
+ SkMatrix::I(), rect, invert);
}
if (devClipBounds.fRight > devPathBounds.fRight) {
rect.iset(devPathBounds.fRight, devPathBounds.fTop,
devClipBounds.fRight, devPathBounds.fBottom);
- DrawNonAARect(renderTargetContext, GrPaint(paint), userStencilSettings, clip, SkMatrix::I(),
- rect, invert);
+ DrawNonAARect(renderTargetContext, GrPaint::Clone(paint), userStencilSettings, clip,
+ SkMatrix::I(), rect, invert);
}
if (devClipBounds.fBottom > devPathBounds.fBottom) {
rect.iset(devClipBounds.fLeft, devPathBounds.fBottom,
@@ -222,7 +222,7 @@ bool GrSoftwarePathRenderer::onDrawPath(const DrawPathArgs& args) {
}
}
if (inverseFilled) {
- DrawAroundInvPath(args.fRenderTargetContext, GrPaint(args.fPaint),
+ DrawAroundInvPath(args.fRenderTargetContext, GrPaint::Clone(args.fPaint),
*args.fUserStencilSettings, *args.fClip, *args.fViewMatrix, devClipBounds,
unclippedDevShapeBounds);
}