[page:Curve] →

[name]

Create a smooth 2d quadratic bezier curve, defined by a startpoint, endpoint and a single control point.

Example

var curve = new v3d.QuadraticBezierCurve( new v3d.Vector2(-10, 0), new v3d.Vector2(20, 15), new v3d.Vector2(10, 0) ); var path = new v3d.Path(curve.getPoints(50)); var geometry = path.createPointsGeometry(50); var material = new v3d.LineBasicMaterial({ color : 0xff0000 }); //Create the final object to add to the scene var curveObject = new v3d.Line(geometry, material);

Constructor

[name]([page:Vector2 v0], [page:Vector2 v1], [page:Vector2 v2])

[page:Vector2 v0] – The startpoint.
[page:Vector2 v1] – The control point.
[page:Vector2 v2] – The endpoint.

Properties

See the base [page:Curve] class for common properties.

[property:Vector2 v0]

The startpoint.

[property:Vector2 v1]

The control point.

[property:Vector2 v2]

The endpoint.

Methods

See the base [page:Curve] class for common methods.
[sourceHint]