org.hermit.geometry.spline
Class CubicSpline

java.lang.Object
  extended by org.hermit.geometry.spline.CubicSpline

public class CubicSpline
extends java.lang.Object

Implementation of a natural cubic spline.


Constructor Summary
CubicSpline(Point[] points)
          Create a cubic spline curve with a specified set of control points.
 
Method Summary
 Point[] interpolate(int steps)
          Interpolate the spline.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CubicSpline

public CubicSpline(Point[] points)
Create a cubic spline curve with a specified set of control points.

Parameters:
points - The control points for this curve.
Method Detail

interpolate

public Point[] interpolate(int steps)
Interpolate the spline.

Parameters:
steps - The number of steps to interpolate in each segment.
Returns:
The interpolated values.