Modifier and Type | Field and Description |
---|---|
static double |
curveCollinearityEpsilon
If the distance between a point and a line is less than this constant, then we consider the point lies on the line.
|
static double |
distanceToleranceManhattan
The Manhattan distance is used in the case when either the line ((x1, y1), (x4, y4)) passes through both (x2, y2) and (x3, y3) or (x1, y1) = (x4, y4).
|
static double |
distanceToleranceSquare
In the case when neither the line ((x1, y1), (x4, y4)) passes through both (x2, y2) and (x3, y3) nor (x1, y1) = (x4, y4) we use the square of the sum of the distances mentioned below in compare to this field as the criterion of good approximation.
|
Constructor and Description |
---|
BezierCurve(List<Point2D> controlPoints)
Constructs new bezier curve.
|
Modifier and Type | Method and Description |
---|---|
List<Point2D> |
getBasePoints()
Treat base points as the points which are enough to construct a shape.
|
List<Point2D> |
getPiecewiseLinearApproximation()
You can adjust precision of the approximation by varying the following parameters: curveCollinearityEpsilon , distanceToleranceSquare , distanceToleranceManhattan
|
public static double curveCollinearityEpsilon
public static double distanceToleranceSquare
public static double distanceToleranceManhattan
public List<Point2D> getBasePoints()
getBasePoints
in interface Shape
List
consisting of shape's base points.
public List<Point2D> getPiecewiseLinearApproximation()
curveCollinearityEpsilon
, distanceToleranceSquare
, distanceToleranceManhattan
List
containing points of piecewise linear approximation for this bezier curve.
Copyright © 1998–2022. All rights reserved.