shape ops work in progress
mostly working on cubic/cubic intersect
git-svn-id: http://skia.googlecode.com/svn/trunk@7266 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/experimental/Intersection/LineParameters.h b/experimental/Intersection/LineParameters.h
index fc1bcc8..8155ad8 100644
--- a/experimental/Intersection/LineParameters.h
+++ b/experimental/Intersection/LineParameters.h
@@ -80,15 +80,9 @@
}
}
- void controlPtDistance(const Cubic& pts, double distance[2]) const {
- for (int index = 0; index < 2; ++index) {
- distance[index] = a * pts[index + 1].x + b * pts[index + 1].y + c;
- }
- }
-
- void controlPtDistance(const Cubic& pts, int i, int j, double distance[2]) const {
- distance[0] = a * pts[i].x + b * pts[i].y + c;
- distance[1] = a * pts[j].x + b * pts[j].y + c;
+ double controlPtDistance(const Cubic& pts, int index) const {
+ assert(index == 1 || index == 2);
+ return a * pts[index].x + b * pts[index].y + c;
}
double controlPtDistance(const Quadratic& pts) const {