Package toxi.geom
Class BezierCurve2D
java.lang.Object
toxi.geom.BezierCurve2D
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidalignHandlesForPoint(int id) static Vec2DcomputePointInSegment(Vec2D a, Vec2D b, Vec2D c, Vec2D d, float t) static Vec2DcomputeTangentInSegment(Vec2D a, Vec2D b, Vec2D c, Vec2D d, float t) booleanisClosed()toLineStrip2D(int res) Computes a list of intermediate curve points for all segments.toPolygon2D(int res)
-
Constructor Details
-
BezierCurve2D
public BezierCurve2D() -
BezierCurve2D
-
-
Method Details
-
computePointInSegment
-
computeTangentInSegment
-
add
-
alignAllHandles
public void alignAllHandles() -
alignHandlesForPoint
public void alignHandlesForPoint(int id) -
isClosed
public boolean isClosed()- Returns:
- true, if the curve is closed. I.e. the first and last control point coincide.
-
toLineStrip2D
Computes a list of intermediate curve points for all segments. For each curve segment the given number of points will be produced.- Parameters:
res- number of points per segment- Returns:
- list of Vec2Ds
-
toPolygon2D
-