diff options
author | Stephen White <senorblanco@chromium.org> | 2018-03-28 14:41:22 -0400 |
---|---|---|
committer | Skia Commit-Bot <skia-commit-bot@chromium.org> | 2018-03-29 14:28:55 +0000 |
commit | 20010e80b637b9c6173c2d3d3c2070bb3b184104 (patch) | |
tree | 59c6ae565ba2416f94dc35bd8c8b613af8a591c2 /src/gpu | |
parent | 16c5d1b0225a80b505e7bf27a075eb07c994a9c0 (diff) |
Reland "GrTessellator: hang fix."
This is a reland of 050c86768a2c24c62655f53ef9b685d40477eccb
Original change's description:
> GrTessellator: hang fix.
>
> Some edges are not coincident with their own endpoints (because floating
> point). If this happens for an edge which is a right-enclosing-edge
> during the Bentley-Ottman simplify() pass, we end up an infinite loop
> attempting to split the edge, since the edge is never to the right of its
> endpoint.
>
> The easiest fix is to simply remove the right-enclosing-edge splitting
> code. This code was originally added before we had proper
> active-edge-list rewinding, and should no longer be necessary.
>
> BUG=802896
>
> Change-Id: Id9f2942b73f01152af8c0088e8c6b1389891d827
> Reviewed-on: https://skia-review.googlesource.com/116920
> Reviewed-by: Robert Phillips <robertphillips@google.com>
> Commit-Queue: Stephen White <senorblanco@chromium.org>
Bug: 802896
Change-Id: I3e48346a8a358ae7d481299a586003e817a519ca
Reviewed-on: https://skia-review.googlesource.com/117121
Reviewed-by: Mike Klein <mtklein@chromium.org>
Commit-Queue: Mike Klein <mtklein@chromium.org>
Diffstat (limited to 'src/gpu')
-rw-r--r-- | src/gpu/GrTessellator.cpp | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/src/gpu/GrTessellator.cpp b/src/gpu/GrTessellator.cpp index 00e5c8a21c..b8ec6551c9 100644 --- a/src/gpu/GrTessellator.cpp +++ b/src/gpu/GrTessellator.cpp @@ -1421,12 +1421,6 @@ bool simplify(VertexList* mesh, Comparator& c, SkArenaAlloc& alloc) { LOG("\nvertex %g: (%g,%g), alpha %d\n", v->fID, v->fPoint.fX, v->fPoint.fY, v->fAlpha); restartChecks = false; find_enclosing_edges(v, &activeEdges, &leftEnclosingEdge, &rightEnclosingEdge); - if (rightEnclosingEdge && !rightEnclosingEdge->isRightOf(v)) { - split_edge(rightEnclosingEdge, v, &activeEdges, &v, c, alloc); - restartChecks = true; - continue; - } - SkASSERT(!rightEnclosingEdge || rightEnclosingEdge->isRightOf(v)); v->fLeftEnclosingEdge = leftEnclosingEdge; v->fRightEnclosingEdge = rightEnclosingEdge; if (v->fFirstEdgeBelow) { |