mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-19 06:00:56 -05:00
Fix to cover the case when Numerical.solveQuadratic return -1 in path._getMonoCurves culculation
This commit is contained in:
parent
2a668dd04e
commit
c5b4828ace
1 changed files with 1 additions and 1 deletions
|
@ -979,7 +979,7 @@ Path.inject(/** @lends Path# */{
|
|||
// Keep then range to 0 .. 1 (excluding) in the search for y
|
||||
// extrema.
|
||||
n = Numerical.solveQuadratic(a, b, c, roots, tMin, tMax);
|
||||
if (n === 0) {
|
||||
if (n < 1) {
|
||||
insertCurve(v);
|
||||
} else {
|
||||
roots.sort();
|
||||
|
|
Loading…
Reference in a new issue