I know how to do linear interpolation, this is what I've build for it at the moment: http://repl.it/BBL9
What I don't see is how I'll do smooth interpolation. I'm coding a mesh deformer and I have a problem due to the in-point and end-point transitions being abrupt, the effect is cut off dramatically like the line on top in the image. I want it to be smooth like the line in the bottom:
So I would like to pass a float from 0.0 to 1.0 and get back the corresponding smooth interpolation float value.
If I can't code it I'm considering doing what I did in nodal editor: Have 2 arrays of 1000 sample values. The first array are values linearly interpolated values from 0.0 to 0.1, while the second is smoothed interpolated values from 0.0 to 1.0.
So I would find the closest value in the linear array and with corresponding index assign the value from the second array. I believe this is called a LUT... This would mean I could generate any curve interpolation without knowing how to calculate it, while would probably not be very accurate.
Is this last idea a bad practice if I can't code the calculation?