Skip to content

Commit 78f9710

Browse files
committed
audio: Avoid accumulation errors in resampler.
Fixes #6391.
1 parent 689218e commit 78f9710

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/audio/SDL_audiocvt.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -247,7 +247,7 @@ SDL_ResampleAudio(const int chans, const int inrate, const int outrate,
247247
*(dst++) = outsample;
248248
}
249249

250-
outtime += outtimeincr;
250+
outtime = outtimeincr * i;
251251
}
252252

253253
return outframes * chans * sizeof (float);

0 commit comments

Comments
 (0)