public final class Bezier extends Object
 Copyright (c) 2013-2019 Delft University of Technology, PO Box 5, 2600 AA, Delft, the Netherlands. All rights reserved. 
 BSD-style license. See OpenTrafficSim License.
 
| Modifier and Type | Method and Description | 
|---|---|
| static OTSLine3D | bezier(int numPoints,
      OTSPoint3D... points)Construct a Bézier curve of degree n. | 
| static OTSLine3D | bezier(OTSPoint3D... points)Construct a Bézier curve of degree n. | 
| static OTSLine3D | cubic(DirectedPoint start,
     DirectedPoint end)Construct a cubic Bézier curve from start to end with two generated control points at half the distance between
 start and end. | 
| static OTSLine3D | cubic(int numPoints,
     DirectedPoint start,
     DirectedPoint end)Construct a cubic Bézier curve from start to end with two generated control points at half the distance between
 start and end. | 
| static OTSLine3D | cubic(int numPoints,
     DirectedPoint start,
     DirectedPoint end,
     double shape)Construct a cubic Bézier curve from start to end with two generated control points at half the distance between
 start and end. | 
| static OTSLine3D | cubic(int numPoints,
     DirectedPoint start,
     DirectedPoint end,
     double shape,
     boolean weighted)Construct a cubic Bézier curve from start to end with two generated control points at half the distance between
 start and end. | 
| static OTSLine3D | cubic(int numPoints,
     OTSPoint3D start,
     OTSPoint3D control1,
     OTSPoint3D control2,
     OTSPoint3D end)Construct a cubic Bézier curve from start to end with two control points. | 
| static void | main(String[] args) | 
public static OTSLine3D cubic(int numPoints, OTSPoint3D start, OTSPoint3D control1, OTSPoint3D control2, OTSPoint3D end) throws OTSGeometryException
numPoints - int; the number of points for the Bézier curvestart - OTSPoint3D; the start point of the Bézier curvecontrol1 - OTSPoint3D; the first control pointcontrol2 - OTSPoint3D; the second control pointend - OTSPoint3D; the end point of the Bézier curveOTSGeometryException - in case the number of points is less than 2 or the Bézier curve could not be
             constructedpublic static OTSLine3D cubic(int numPoints, DirectedPoint start, DirectedPoint end) throws OTSGeometryException
numPoints - int; the number of points for the Bézier curvestart - DirectedPoint; the directed start point of the Bézier curveend - DirectedPoint; the directed end point of the Bézier curveOTSGeometryException - in case the number of points is less than 2 or the Bézier curve could not be
             constructedpublic static OTSLine3D cubic(int numPoints, DirectedPoint start, DirectedPoint end, double shape) throws OTSGeometryException
numPoints - int; the number of points for the Bézier curvestart - DirectedPoint; the directed start point of the Bézier curveend - DirectedPoint; the directed end point of the Bézier curveshape - shape factor; 1 = control points at half the distance between start and end, > 1 results in a pointier
            shape, < 1 results in a flatter shape, value should be above 0OTSGeometryException - in case the number of points is less than 2 or the Bézier curve could not be
             constructedpublic static OTSLine3D cubic(int numPoints, DirectedPoint start, DirectedPoint end, double shape, boolean weighted) throws OTSGeometryException
numPoints - int; the number of points for the Bézier curvestart - DirectedPoint; the directed start point of the Bézier curveend - DirectedPoint; the directed end point of the Bézier curveshape - shape factor; 1 = control points at half the distance between start and end, > 1 results in a pointier
            shape, < 1 results in a flatter shape, value should be above 0weighted - boolean; control point distance relates to distance to projected point on extended line from other endOTSGeometryException - in case the number of points is less than 2 or the Bézier curve could not be
             constructedpublic static OTSLine3D cubic(DirectedPoint start, DirectedPoint end) throws OTSGeometryException
start - DirectedPoint; the directed start point of the Bézier curveend - DirectedPoint; the directed end point of the Bézier curveOTSGeometryException - in case the number of points is less than 2 or the Bézier curve could not be
             constructedpublic static OTSLine3D bezier(int numPoints, OTSPoint3D... points) throws OTSGeometryException
numPoints - int; the number of points for the Bézier curve to be constructedpoints - OTSPoint3D...; the points of the curve, where the first and last are begin and end point, and the
            intermediate ones are control points. There should be at least two points.OTSGeometryException - in case the number of points is less than 2 or the Bézier curve could not be
             constructedpublic static OTSLine3D bezier(OTSPoint3D... points) throws OTSGeometryException
points - OTSPoint3D...; the points of the curve, where the first and last are begin and end point, and the
            intermediate ones are control points. There should be at least two points.OTSGeometryException - in case the number of points is less than 2 or the Bézier curve could not be
             constructedpublic static void main(String[] args) throws OTSGeometryException
args - String[]; argsOTSGeometryException - neCopyright © 2014–2019 Delft University of Technology. All rights reserved.