Closed
Description
Reproducer
With ffmpeg i've converted a high quality mp3 (320kbps) to a very low quality mp3 (32kbps), and then I'm converting this to high quality adts (192k), and finally I'm trying to write tags using lofty:
> cargo run --example tag_writer -- ghosts-3-09.aac
thread 'main' (51962) panicked at lofty/../examples/tag_writer.rs:39:10:
ERROR: Failed to read file!: FileDecoding(Aac: "File contains an invalid sample frequency index")
note: run with `RUST_BACKTRACE=1` environment variable to display a backtraceThe rough ffmpeg sequence is something like this, but note that I am not able to reproduce this with other files:
ffmpeg -i low.mp3 -ab 32k low.mp3
ffmpeg -i low.mp3 -ab 192 -t adts high.aac
Summary
I've tried to reproduce this with other songs, but it only happens with this one. The weird conversions are part of the testing processes of one of my tools.
Note that it can be decoded by ffmpeg on my machine:
> ffmpeg -i ghosts-3-09.aac ghosts-3-09.wavI've included the .aac file which causes lofty to error in ghosts.zip as an attachment.
Note that the original song is part of Ghosts by Nine Inch Nails, which is BY-NC-SA.
Expected behavior
No response
Activity
Serial-ATA commentedon Jan 7, 2026
Thanks!