interpolate
public void interpolate(Point flyweight,
Point initialValue,
Point currentValue,
float alpha)
The interpolation algorithm. This takes the initial value, the current value, and the ratio of initial value to current value. The result is then stored in the flyweight argument for use.
- Specified by:
interpolate
in interface Interpolator<Point>
- Parameters:
flyweight
- the flyweight value is where the results are stored
initialValue
- the initial value
currentValue
- the current value
alpha
- a value between 0.0f to 1.0f. When alpha is 0.0f, the value should always be the initial value. When alpha is at 1.0f, the value should always be the current value.