Based on logic, I think the else if statement means to refer to c1 rather than c0 again, but I'd like to verify with you guys.

This commit is contained in:
Jono Brandel 2012-02-07 09:10:33 -08:00
parent 772174cedc
commit ad811827fc

View file

@ -140,7 +140,7 @@ var PathFitter = Base.extend({
c1 = C[1][0] + C[1][1];
if (Math.abs(c0) > epsilon) {
alpha1 = alpha2 = X[0] / c0;
} else if (Math.abs(c0) > epsilon) {
} else if (Math.abs(c1) > epsilon) {
alpha1 = alpha2 = X[1] / c1;
} else {
// Handle below