Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## toxi.math
Class CosineInterpolation

    java.lang.Object
      toxi.math.CosineInterpolation

All Implemented Interfaces:
  InterpolateStrategy

    public class CosineInterpolation

extends java.lang.Object
implements InterpolateStrategy

Implementation of the cosine interpolation function: i = b+(a-b)*(0.5+0.5*cos(f*PI))

Constructor Summary
`CosineInterpolation()`

Method Summary
`float` | `interpolate(float a, float b, float f)` Implements an interpolation equation.

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### CosineInterpolation

    public CosineInterpolation()

Method Detail

### interpolate

    public final float interpolate(float a,
                                   float b,
                                   float f)

  Description copied from interface: `InterpolateStrategy`
  Implements an interpolation equation.

  Specified by:
    `interpolate` in interface `InterpolateStrategy`
  Parameters:
    `a` - current value
    `b` - target value
    `f` - normalized interpolation factor (0.0 .. 1.0)
  Returns:
    interpolated value

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD