diff options
author | robertphillips <robertphillips@google.com> | 2014-09-16 09:43:31 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2014-09-16 09:43:32 -0700 |
commit | c506e3007e53fe7d1a77991de11fdb50a86fd532 (patch) | |
tree | 5e693bd5c4506d75b79563ab19b8a0d2f7270b7a /tests/PathTest.cpp | |
parent | a32f1758b7ebd889eecfdc67c935e7edcedc5be3 (diff) |
Fix convexicator bug
BUG=crbug.com/412640
R=caryclark@google.com, bsalomon@google.com
Author: robertphillips@google.com
Review URL: https://codereview.chromium.org/573763002
Diffstat (limited to 'tests/PathTest.cpp')
-rw-r--r-- | tests/PathTest.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/PathTest.cpp b/tests/PathTest.cpp index 121bce9a1b..1f0422d788 100644 --- a/tests/PathTest.cpp +++ b/tests/PathTest.cpp @@ -1195,6 +1195,17 @@ static void test_convexity2(skiatest::Reporter* reporter) { stroke.applyToPath(&strokedSin, strokedSin); check_convexity(reporter, strokedSin, SkPath::kConcave_Convexity); check_direction(reporter, strokedSin, kDontCheckDir); + + // http://crbug.com/412640 + SkPath degenerateConcave; + degenerateConcave.moveTo(148.67912f, 191.875f); + degenerateConcave.lineTo(470.37695f, 7.5f); + degenerateConcave.lineTo(148.67912f, 191.875f); + degenerateConcave.lineTo(41.446522f, 376.25f); + degenerateConcave.lineTo(-55.971577f, 460.0f); + degenerateConcave.lineTo(41.446522f, 376.25f); + check_convexity(reporter, degenerateConcave, SkPath::kConcave_Convexity); + check_direction(reporter, degenerateConcave, SkPath::kUnknown_Direction); } static void check_convex_bounds(skiatest::Reporter* reporter, const SkPath& p, |