Bugzilla – Bug 7957
VBRI header not read in MP3 files
Last modified: 2009-07-31 10:20:01 UTC
(support ref# 080422-000123) Customer has his music ripped all in MP3 243kbps VBR. While these files play fine, they are listed in SC and on the player as 160kbps CBR. I got a test file and confirmed this is true. SqueezeCenter reports it's a 160 CBR file. Foobar2000 reports it's a 243 kbps VBR file. MP3tag also reports it's a 243 kbps file.
Created attachment 3281 [details] MP3 file's bitrate is displayed incorrectly as 160 CBR, when it's actually 243 VBR.
problem is the VBR header is VBRI format, which MP3::Info doesn't appear to support. Details on header format can be found here: http://www.codeproject.com/KB/audio-video/mpegaudioinfo.aspx
Created attachment 3282 [details] read VBRI
Thanks KDF! Andy, is this a safe change for 7.0.1?
Weird, I had not heard of VBRI before. Thanks, will apply the patch.
one more minor additional change to get the quality factor correctly (trivial really, since we don't make use of this info in SC): Index: server/lib/MP3/Info.pm =================================================================== --- server/lib/MP3/Info.pm (revision 19132) +++ server/lib/MP3/Info.pm (working copy) @@ -1830,7 +1830,7 @@ # start with quality factor at position 8 _vbr_seek($fh, \$off, \$bytes, 4); _vbr_seek($fh, \$off, \$bytes, 2); - $vbr{scale} = _unpack_head($bytes); + $vbr{scale} = unpack('l', pack('L', unpack('n', $bytes))); # Then Bytes, as position 10 _vbr_seek($fh, \$off, \$bytes);
change 19133 has the fix for quality. It all now matches that which is reported by the MPEG Audio Info tool from the codeproject site (interestingly, the tool can also report the bitrate of each frame. Frame 1 shows where SC was getting the 160kbps CBR from).
Created attachment 3287 [details] screencap and just for the record, a cap of the info shown from the mpeg audio tool.
Fixed in change 19127.
Verified Fixed with SqueezeCenter Version: 7.0.1 - 19422
This bug has recently been fixed in the latest release of SqueezeCenter 7.0.1 Please try that version, if you still see the error, then reopen this bug. To download this version, please navigate to: http://www.slimdevices.com/su_downloads.html
Reduce number of active targets for SC