Okay, with a fairly modern, overcompressed track at about 91dB average volume (after being scaled via --scale), the MP3 Xing/Info tag should indicate a peak amplitude of around 0.4 or something, right?
Well, on this track, with --replaygain-accurate invoked, I'm getting
6.73E-39
which, frankly, makes no sense whatsoever.
So either i'm calculating it wrong, or the implied syntax (where 1.0 is full scale peaks) is incorrect.
So, could someone help me out here?
The 4 byte value from the header on this track is 0x004945be, which converted to a 32-bit float is roughly 6.73E-39.
Is this a signing issue, or is this not an IEEE 754 float at all?
Summary:
Info tag "Peak Sample" bytes contain hexidecimal 00 49 45 BE.
This is an integer 4801982
Which, converted to IEEE 754 floating-point, is 6.73E-39 (a very, very small number).
Peak sample should realistically be between 0.1 and 1 (full scale) for a track already WaveGained before encoding.
What's the deal?
Gabriel
Feb 13 2005, 16:25
It's an integer, fixed point:
nPeakSignalAmplitude = abs((int)((((FLOAT)gfc->PeakSample) / 32767.0 ) * pow(2,23) +.5));
thanks!
That means your
page is wrong...
Actually, ok then what the heck IS this number you're storing in the tag?? Why not store either the peaks relative to full scale (ie with 1 being full scale, like your page describes) or the peak sample value (which is really actually quite useful). I don't even understand what this "peak signal amplitude" indicates.
Gabriel
Feb 14 2005, 00:55
It is the peak relative to full scale, but in fixed point.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please
click here.