Both to be perfectly accurate. But changing it now would make files using the existing algorithm behave differently. I probably won’t change it for GH1 any more. Here are the interpolation schemes that will be available in GH2:
- Block: nearest value wins (same as in GH1)
- Linear: straight interpolation between adjacent values (same as GH1)
- Log-Linear: straight interpolation between adjacent values, but “straight” in a logarithmic sense. Only works on positive values.
- Cubic: standard cubic interpolation, but correct unlike in GH1
- Cubic Monotone: a cubic scheme which prevents any overshooting. If a sample is higher than both its immediate neighbours, the highest value on the interpolation spline is guaranteed to be at that sample.
- Akima: a cubic scheme with reduces overshoots.
- Equidistant Polynomial: fit a polynomial function to the samples, only works reasonably well if the samples are equi-spaced.
- Neville Polynomial: more robust polynomial fitter.
- Floater-Hormann: for a rational (as opposed to polynomial) function to the samples.
- Bulirsch-Stoer: an early rational fitter, often yields poles within the interpolation domain where the values on either side go to infinity.
There’s also a Fourier transform, which can be used as an interpolation scheme. It has an interesting feature that it is a cyclical interpolation, meaning the pattern repeats smoothly all along the x-axis. The samples are necessarily equi-spaced with this scheme.
I also added a Blend Curve interpolation which assumes a constant value before and after the first and last grips. It also supports various interpolation schemes including cosine, smooth, smoother (degree=5) and smoothest (degree=7):