From d4d2075040a7010e8f8a109b028f08fbd68d5918 Mon Sep 17 00:00:00 2001 From: hkrish Date: Mon, 17 Jun 2013 22:20:16 +0530 Subject: [PATCH] Fix: Use absolute coordinates from #Curve.getValues() directly while calculating the curvature --- src/path/Curve.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/path/Curve.js b/src/path/Curve.js index 10fd297a..9bfb806a 100644 --- a/src/path/Curve.js +++ b/src/path/Curve.js @@ -813,11 +813,11 @@ statics: { // k = (2/3) * h / a^2 var line, point; if (offset === 0) { - line = new Line(values[0], values[1], values[2], values[3], true); - point = new Point(values[6]+values[4], values[7]+values[5]); + line = new Line(values[0], values[1], values[2], values[3]); + point = new Point(values[4], values[5]); } else { - line = new Line(values[6], values[7], values[4], values[5], true); - point = new Point(values[0]+values[2], values[1]+values[3]); + line = new Line(values[6], values[7], values[4], values[5]); + point = new Point(values[2], values[3]); } var a = line.getLength(), h = line.getDistance(point);