`getPointAtLength` returns incorrect value for lengths exactly on segment intersections.
getPointAtLength returns incorrect value for length exactly on segment intersections. I think the culprit is the if statement
// native `getPointAtLength` behavior when the given distance
// is higher than total length
if (distance > totalLength - DISTANCE_EPSILON) {
return { x, y };
}
that should only go through if we're at the end of sub path, not at the end of any individual segment.
Can't confirm out of my head. What do you suggest?
I'm not sure yet. I'm making something pretty complex using this library and I've encountered a few different issues, but I'll have to gather more evidence before I report on them. As for this issue, the problem went away when I copied the function and removed the if statement (but obviously it doesn't work correctly when at the very end of a path).
I'll see if I can provide a few test cases in the coming days
I also ran into the same issue. I am sampling a simple path with L commands