The ResampleStream class of the Arduino Audio Tools project provides some flexible resampling functionality both on the input and the output side. To calculate the values it just uses a simple but efficient linear interpolation.

I finally managed to provide an extended ResampleStreamT resampling class that uses some alternative interpolation method implementations:

Here is an overview with the advantages and disadvantages:

Method Quality CPU Cost Artifacts Interpolates Sample Points
Linear Low Very Low High Yes
B-Spline (Cubic) Moderate Medium Low No
Lagrange (Order 3) High (order-dependent) High Moderate (oscillation) Yes
Cubic Hermite High Medium Low Yes
Parabolic (Quadratic) Moderate Low Moderate Yes

Further information can be found in the Resampling Wiki!


0 Comments

Leave a Reply

Avatar placeholder

Your email address will not be published. Required fields are marked *