mirror of
https://github.com/Ardour/ardour.git
synced 2025-12-15 19:16:40 +01:00
fix required-sample count for cubic interpolation.
I have not proved if the iterative process in CubicInterpolation::interpolate() is identical to (nframes * fabs(_actual_speed)), however ceil() of it is empirically always larger. Also, the cubic interpolation needs +2 samples. Ardour3: Too close to call :) git-svn-id: svn://localhost/ardour2/branches/3.0@13392 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
cb57b95480
commit
a8cf2aa4f9
1 changed files with 1 additions and 1 deletions
|
|
@ -578,7 +578,7 @@ AudioDiskstream::process (framepos_t transport_frame, pframes_t nframes, framecn
|
|||
/* no varispeed playback if we're recording, because the output .... TBD */
|
||||
|
||||
if (rec_nframes == 0 && _actual_speed != 1.0f) {
|
||||
necessary_samples = (framecnt_t) floor ((nframes * fabs (_actual_speed))) + 1;
|
||||
necessary_samples = (framecnt_t) ceil ((nframes * fabs (_actual_speed))) + 2;
|
||||
} else {
|
||||
necessary_samples = nframes;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue