Curve

QuadraticBezierCurve3

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

Example

var curve = new v3d.QuadraticBezierCurve3( new v3d.Vector3(-10, 0, 0), new v3d.Vector3(20, 15, 0), new v3d.Vector3(10, 0, 0) ); var points = curve.getPoints(50); var geometry = new v3d.BufferGeometry().setFromPoints(points); var material = new v3d.LineBasicMaterial({ color : 0xff0000 }); // Create the final object to add to the scene var curveObject = new v3d.Line(geometry, material);

Constructor

QuadraticBezierCurve3(v0 : Vector3, v1 : Vector3, v2 : Vector3)

v0 – The starting point
v1 – The middle control point
v2 – The ending point

Properties

See the base Curve class for common properties.

.isQuadraticBezierCurve3 : Boolean

Used to check whether this or derived classes are QuadraticBezierCurve3s. Default is true.

You should not change this, as it used internally for optimisation.

.v0 : Vector3

The startpoint.

.v1 : Vector3

The control point.

.v2 : Vector3

The endpoint.

Methods

See the base Curve class for common methods.

Source

For more info on how to obtain the source code of this module see this page.