diff options
author | Brian Salomon <bsalomon@google.com> | 2017-05-08 10:43:33 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2017-05-10 14:48:47 +0000 |
commit | ac70f84e7f4fc9ddd344753b92cdf4be540d32bf (patch) | |
tree | 4b813dd3d6fae01afe6727a6897faf4c31fb240c /gm/constcolorprocessor.cpp | |
parent | 0418a888d31689f5358b6b90fd09287aeba368db (diff) |
Move all non-AA fill rect ops off of GrLegacyMeshDrawOp.
This adds perspective to GrNewNonAAFillRectOp, renames it to GrNonAAFillRectOp, and deletes the previous version of that namespace.
Change-Id: I20f35bf019f9c9105e6ec83dda11328451138109
Reviewed-on: https://skia-review.googlesource.com/15634
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
Diffstat (limited to 'gm/constcolorprocessor.cpp')
-rw-r--r-- | gm/constcolorprocessor.cpp | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/gm/constcolorprocessor.cpp b/gm/constcolorprocessor.cpp index 2e0fde2861..bbfca008bd 100644 --- a/gm/constcolorprocessor.cpp +++ b/gm/constcolorprocessor.cpp @@ -18,7 +18,7 @@ #include "SkGradientShader.h" #include "effects/GrConstColorProcessor.h" #include "ops/GrDrawOp.h" -#include "ops/GrRectOpFactory.h" +#include "ops/GrNonAAFillRectOp.h" namespace skiagm { /** @@ -109,11 +109,9 @@ protected: sk_sp<GrFragmentProcessor> fp(GrConstColorProcessor::Make(color, mode)); grPaint.addColorFragmentProcessor(std::move(fp)); - - std::unique_ptr<GrLegacyMeshDrawOp> op(GrRectOpFactory::MakeNonAAFill( - grPaint.getColor(), viewMatrix, renderRect, nullptr, nullptr)); - renderTargetContext->priv().testingOnly_addLegacyMeshDrawOp( - std::move(grPaint), GrAAType::kNone, std::move(op)); + renderTargetContext->priv().testingOnly_addDrawOp( + GrNonAAFillRectOp::Make(std::move(grPaint), viewMatrix, renderRect, + nullptr, nullptr, GrAAType::kNone)); // Draw labels for the input to the processor and the processor to the right of // the test rect. The input label appears above the processor label. |