How do you do bicubic (or other non-linear) interpolation of re-sampled audio data?
I'm writing some code that plays back WAV files at different speeds, so that the wave is either slower and lower-pitched, or faster and higher-pitched. I'm currently using simple linear interpolation, like so: int newlength = (int)Math.Round(rawdata.Length * lengthMultiplier); float[] output = new float[newlength]; for (int i = 0; i < newlength; i++) { float realPos = i / lengthMultiplier; int iLow = (int)realPos; int iHigh = iLow + 1; float remainder = realPos - (float)iLow; float lowval = 0; float highval = 0; if ((iLow >= 0) && (iLow < rawdata.Length)) { lowval = rawdata[iLow]; } if ((iHigh