mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-01-05 20:32:00 -05:00
Curve-line intersection fix
This commit is contained in:
parent
bec1a91812
commit
ac04029f6e
1 changed files with 1 additions and 1 deletions
|
@ -1460,7 +1460,7 @@ new function() { // Scope for methods that require numerical integration
|
|||
// We do have a point on the infinite line. Check if it falls on
|
||||
// the line *segment*.
|
||||
if (point.x >= 0 && point.x <= rl2x){
|
||||
var tl = Curve.getParameterOf(vl, point.x, point.y);
|
||||
var tl = Curve.getParameterOf([0, 0, 0, 0, rl2x, 0, rl2x, 0], point.x, 0);
|
||||
// Interpolate the parameter for the intersection on line.
|
||||
var t1 = flip ? tl : t,
|
||||
t2 = flip ? t : tl;
|
||||
|
|
Loading…
Reference in a new issue