mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-07 13:22:07 -05:00
Merge pull request #1111 from iconexperience/resolveCrossings-patch
Patch for resolveCrossings() to fix #1110
This commit is contained in:
commit
d1c8ed9203
1 changed files with 3 additions and 1 deletions
|
@ -910,11 +910,13 @@ PathItem.inject(new function() {
|
||||||
prev._handleOut._set(0, 0);
|
prev._handleOut._set(0, 0);
|
||||||
next._handleIn._set(0, 0);
|
next._handleIn._set(0, 0);
|
||||||
var curve = prev.getCurve();
|
var curve = prev.getCurve();
|
||||||
if (curve.isStraight() && curve.getLength() === 0)
|
if (curve.isStraight() && curve.getLength() === 0) {
|
||||||
|
next._handleIn.set(prev._handleIn.x, prev._handleIn.y);
|
||||||
prev.remove();
|
prev.remove();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
if (hasCrossings) {
|
if (hasCrossings) {
|
||||||
// Divide any remaining intersections that are still part of
|
// Divide any remaining intersections that are still part of
|
||||||
// valid paths after the removal of overlaps.
|
// valid paths after the removal of overlaps.
|
||||||
|
|
Loading…
Reference in a new issue