The list of methods to do Geometry Algorithm are organized into topic(s).
Point[]
applyDynamism(final Point[] spline, final int msForMove, final int msPerMove) Omits points along the spline in order to move in steps rather then pixel by pixel
final int numPoints = spline.length;
final double msPerPoint = (double) msForMove / (double) numPoints;
final double undistStep = msPerMove / msPerPoint;
final int steps = (int) Math.floor(numPoints / undistStep);
final Point[] result = new Point[steps];
final double[] gaussValues = gaussTable(result.length);
double currentPercent = 0;
for (int i = 0; i < steps; i++) {
...
void
applyMidPointApprox(CubicCurve2D cubic, QuadCurve2D quad) Converts a cubic Bézier to a quadratic one, using the mid-point approximation
double a0x = cubic.getX1(), a0y = cubic.getY1();
double a1x = cubic.getX2(), a1y = cubic.getY2();
double p0x = (3 * cubic.getCtrlX1() - a0x) / 2.0;
double p0y = (3 * cubic.getCtrlY1() - a0y) / 2.0;
double p1x = (3 * cubic.getCtrlX2() - a1x) / 2.0;
double p1y = (3 * cubic.getCtrlY2() - a1y) / 2.0;
quad.setCurve(a0x, a0y, (p0x + p1x) / 2, (p0y + p1y) / 2, a1x, a1y);
double
area2(Point2D a, Point2D b, Point2D c) Calculates twice the area of a triangle for points specified in counter-clockwise order (if the points are specified in clockwise order the result will be negative).
double ax = a.getX();
double ay = a.getY();
double bx = b.getX();
double by = b.getY();
double cx = c.getX();
double cy = c.getY();
return (ax - cx) * (by - cy) - (ay - cy) * (bx - cx);