Fix curve evaluate function to finite

This commit is contained in:
sapics 2015-10-17 14:28:11 +09:00
parent 37e3ac7883
commit 8dfb5191fa

View file

@ -1087,8 +1087,10 @@ new function() { // Scope for methods that require private functions
}
// Now normalize x & y
var len = Math.sqrt(x * x + y * y);
x /= len;
y /= len;
if (len) {
x /= len;
y /= len;
}
}
if (type === 3) {
// Calculate 2nd derivative, and curvature from there: