public class Bezier3
extends Object
3D Bezier curve implementation. All points are in the same space - p1 and p2 are not relative to p0 and p3, respectively.
See
Wikipedia
-
Field Summary 
Fields
javax.vecmath.Vector3d
javax.vecmath.Vector3d
javax.vecmath.Vector3d
javax.vecmath.Vector3d
-
Constructor Summary 
Constructors
-
Method Summary 
javax.vecmath.Vector3d
interpolate along the path.
-
Field Details 
-
p0 
public javax.vecmath.Vector3d p0
-
p1 
public javax.vecmath.Vector3d p1
-
p2 
public javax.vecmath.Vector3d p2
-
p3 
public javax.vecmath.Vector3d p3
-
Constructor Details 
-
Bezier3 
public Bezier3()
-
Method Details 
-
interpolate 
public javax.vecmath.Vector3d interpolate(double i)
interpolate along the path. This code is slow, intuitive, and it works.
- Parameters:
i
- 0...1 inclusive
- Returns:
- the interpolated
Vector3d
along the path.