diff options
author | 2017-09-07 18:33:08 +0000 | |
---|---|---|
committer | 2017-09-07 18:33:22 +0000 | |
commit | e5ede4b138e84d05d63c9ab7f426884dc9b4d926 (patch) | |
tree | dfbaa75e3d7d3e5e70deed7585419ce2610e9978 /src/gpu/ops/GrMSAAPathRenderer.cpp | |
parent | b3e39f67599adf418215652fe714d3883dd5fd88 (diff) |
Revert "Improve GrPathRendererChain heuristics"
This reverts commit 60f42494f5d45c38e260ce089cdddfb600f799b2.
Reason for revert: breaking gold
Original change's description:
> Improve GrPathRendererChain heuristics
>
> Changes GrPathRenderer::canDrawPath to return a 'CanDrawPath' enum,
> which contains a new kAsBackup value that means "I'm better than SW,
> but give the path renderers below me a chance first."
>
> Bug: skia:
> Change-Id: I45aac5462ca1bc0bc839eb1c315db9493901a07e
> Reviewed-on: https://skia-review.googlesource.com/42222
> Reviewed-by: Brian Osman <brianosman@google.com>
> Reviewed-by: Brian Salomon <bsalomon@google.com>
> Commit-Queue: Chris Dalton <csmartdalton@google.com>
TBR=jvanverth@google.com,bsalomon@google.com,brianosman@google.com,csmartdalton@google.com,senorblanco@google.com
Change-Id: I46020dbd56b6f6b88668894285b9b7b80f89b9a2
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:
Reviewed-on: https://skia-review.googlesource.com/43780
Reviewed-by: Chris Dalton <csmartdalton@google.com>
Commit-Queue: Chris Dalton <csmartdalton@google.com>
Diffstat (limited to 'src/gpu/ops/GrMSAAPathRenderer.cpp')
-rw-r--r-- | src/gpu/ops/GrMSAAPathRenderer.cpp | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/gpu/ops/GrMSAAPathRenderer.cpp b/src/gpu/ops/GrMSAAPathRenderer.cpp index b80a811430..ef19367f61 100644 --- a/src/gpu/ops/GrMSAAPathRenderer.cpp +++ b/src/gpu/ops/GrMSAAPathRenderer.cpp @@ -682,18 +682,15 @@ bool GrMSAAPathRenderer::internalDrawPath(GrRenderTargetContext* renderTargetCon return true; } -GrPathRenderer::CanDrawPath GrMSAAPathRenderer::onCanDrawPath(const CanDrawPathArgs& args) const { +bool GrMSAAPathRenderer::onCanDrawPath(const CanDrawPathArgs& args) const { // If we aren't a single_pass_shape, we require stencil buffers. if (!single_pass_shape(*args.fShape) && args.fCaps->avoidStencilBuffers()) { - return CanDrawPath::kNo; + return false; } // This path renderer only fills and relies on MSAA for antialiasing. Stroked shapes are // handled by passing on the original shape and letting the caller compute the stroked shape // which will have a fill style. - if (!args.fShape->style().isSimpleFill() || GrAAType::kCoverage == args.fAAType) { - return CanDrawPath::kNo; - } - return CanDrawPath::kYes; + return args.fShape->style().isSimpleFill() && (GrAAType::kCoverage != args.fAAType); } bool GrMSAAPathRenderer::onDrawPath(const DrawPathArgs& args) { |