From ac93ff038eaa9b05918b78583f1be4ead39fca41 Mon Sep 17 00:00:00 2001 From: Christopher Snowhill Date: Sun, 23 Mar 2025 20:22:27 -0700 Subject: [PATCH] Bug Fix: Fix minimp3 seek position Seek offset is scaled by the number of channels in the file. Oops again. Signed-off-by: Christopher Snowhill --- Plugins/minimp3/MP3Decoder.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Plugins/minimp3/MP3Decoder.m b/Plugins/minimp3/MP3Decoder.m index 8e04866f9..19a13f87c 100644 --- a/Plugins/minimp3/MP3Decoder.m +++ b/Plugins/minimp3/MP3Decoder.m @@ -293,7 +293,7 @@ static int mp3_seek_callback(uint64_t position, void *user_data) { frame = totalFrames; if(seekable) { - int error = mp3dec_ex_seek(&_decoder_ex, frame); + int error = mp3dec_ex_seek(&_decoder_ex, frame * _decoder_ex.info.channels); if(error < 0) { return -1; }