Implement streaming decoder, seeking, persistence, file switching, album art

Replace fire-and-forget decode_audio() with a streaming Decoder that uses
libswresample to convert planar float to interleaved stereo, fixing the
sped-up audio bug and eliminating multi-GB memory usage for long files.

Add 10-second rewind/fast-forward, stop (pause in place), position
persistence per file via positions.txt, directory scanning with file
switching, embedded album art display, and a progress bar. Handles both
old and new FFmpeg channel layout APIs via version preprocessor check.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Michael Smith
2026-02-10 20:41:40 +01:00
parent d03d0a1f8b
commit 9db8dfdd48
3 changed files with 558 additions and 148 deletions

1
.gitignore vendored
View File

@@ -2,4 +2,5 @@
/build/sdlamp2.dSYM
*.mp3
*.m4a
positions.txt