Fix last pathops skp bug
authorcaryclark <caryclark@google.com>
Wed, 18 Jun 2014 14:24:19 +0000 (07:24 -0700)
committerCommit bot <commit-bot@chromium.org>
Wed, 18 Jun 2014 14:24:19 +0000 (07:24 -0700)
commite4097e3a0b10bb0047a45b6949ca01826f0807a7
tree1b04df78fa4a4aa239d09184e88929102d12886a
parent683e90611c8a536c3c5feedea27bbbefedf746d2
Fix last pathops skp bug

This fixes the last bug discovered by iterating through the 800K
skp corpus representing the top 1M websites. For every clip on the
stack, the paths are replaced with the pathop intersection. The
resulting draw is compared with the original draw for pixel errors.

At least two prominent bugs remain. In one, the winding value is
confused by a cubic with an inflection. In the other, a quad/cubic
pair, nearly coincident, fails to find an intersection.

These minor changes include ignoring very tiny self-intersections
of cubics, and processing degenerate edges that don't connect to
anything else.

R=reed@android.com
TBR=reed

Author: caryclark@google.com

Review URL: https://codereview.chromium.org/340103002
12 files changed:
src/pathops/SkDCubicIntersection.cpp
src/pathops/SkOpSegment.cpp
src/pathops/SkOpSegment.h
src/pathops/SkPathOpsDebug.cpp
tests/PathOpsCubicQuadIntersectionTest.cpp
tests/PathOpsDebug.cpp
tests/PathOpsOpTest.cpp
tests/PathOpsSkpTest.cpp
tests/PathOpsTestCommon.cpp
tests/PathOpsTestCommon.h
tools/pathops_sorter.htm
tools/pathops_visualizer.htm