mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-03 19:45:44 -05:00
parent
17d000266f
commit
d89995a781
1 changed files with 5 additions and 2 deletions
|
@ -401,14 +401,17 @@ PathItem.inject(new function() {
|
|||
// the ray. This essentially is not a crossing.
|
||||
if (Numerical.isZero(slope)
|
||||
&& !Curve.isStraight(values)
|
||||
// NOTE: We include 0 in the checks, since
|
||||
// even following a horizontal tangent is a
|
||||
// tip that is only touched, not crossed.
|
||||
// Does the slope over the beginning change?
|
||||
|| t < tMin && prevCurve
|
||||
&& slope * Curve.getTangent(
|
||||
prevCurve.values, 1).y < 0
|
||||
prevCurve.values, 1).y <= 0
|
||||
// Does the slope over the end change?
|
||||
|| t > tMax && nextCurve
|
||||
&& slope * Curve.getTangent(
|
||||
nextCurve.values, 0).y < 0) {
|
||||
nextCurve.values, 0).y <= 0) {
|
||||
if (x > xBefore && x < xAfter) {
|
||||
++windLeft;
|
||||
++windRight;
|
||||
|
|
Loading…
Reference in a new issue