Improving ReplayGain, some ideas for Devs etc
Improving ReplayGain, some ideas for Devs etc
Nov 18 2003, 17:04
Joined: 5-November 01
From: Yorkshire, UK
Member No.: 409
Every now and again I wish I had the time to update the ReplayGain website and add some new ideas, and maybe even clarify some old ones. I don't, so this thread will have to do.
Firstly, the format used to store ReplayGain info in files is not documented correctly on the ReplayGain website, and it would be good to "publish" what has emerged as the standard for each format.
Secondly, what is stored is not documented correctly on the ReplayGain website, and I'd like to re-examine what is stored...
One change has already happened, and I think it's a good change:
Forget Radio and Audiophile - Track and Album are much better names.
(that's an open admission of me being wrong, for anyone who discussed this with me previously!)
So, we store:
ReplayGain Track adjustment
ReplayGain Album adjustment
(ReplayGain) Track peak
(ReplayGain) Album peak
(this last one wasn't in the original proposal, but it has been widely used - I've put it in bold to remind me to include it in the update)
That makes sense, and most software supports this. I'd like to formalise some extensions, some of which were there from the start, and others that have cropped up more recently:
1. (ReplayGain) undo adjustment
- this is written when the gain of the file is changed (e.g. by mp3gain, or by decoding with ReplayGain enabled), and is the gain change required to put the file back to where it started.
e.g. If I apply -8dB gain change using mp3gain, then
(ReplayGain) undo adjustment = +8dB
e.g. If I use --scale 0.5 when encoding (for whatever reason?!), then
(ReplayGain) undo adjustment = +6dB
If the gain of an already ReplayGained file is changed, the original four values (Track and Album adjustment and peak) should be updated so that they are correct for the new audio data. (see an example in this thread: http://www.hydrogenaudio.org/forums/index....topic=15412&hl= )
I can't see any argument against defining this field. It would be zero (or absent) if the audio file hasn't been altered. It's useful in all formats because you can always apply wavgain before encoding, and it would be nice to know that this has been done.
2. ReplayGain calculation method
OK - I've had this argument before, but this really is important. ReplayGain can be improved, but you'll never know whether files are tagged using the old or new ReplayGain calculation unless the calculation method (actually a number which corresponds to the method) is stored. This doesn't increase the complexity of players, as they won't care - it just makes it very easy to pick out files that were tagged with the old version, and update them.
3. ReplayGain lossy approximation
This is just a single bit: 0 or 1.
0= this ReplayGain info has been calculated from the data in this file
1=this file has been lossily encoded/transcoded since this ReplayGain info was calculated.
What's the point of this? If you have a file with ReplayGain info, you can transcode it and copy the RG info across. It'll be close enough to give you excellent loudness equalisation, and you won't have to re-calculate it. Yet they'll be a label there to tell all you anal retentives that it's not quite right, and should be recalculated if you want to be 100% sure (especially important for peak amplitude).
You could (should?) have one “ReplayGain lossy approximation” bit for each of the four values, which gives you the chance (for example) of re-calculating the peak values (quick, and important - so let's do it), but leaving the ReplayGain values (slow, and unimportant - so let's not do it).
4. ReplayGain user adjustment
Instead of suggesting that users should change the calculated values if they wish, give them a field to enter their own value if they really have to. Players should give the option to read the user value in preference to any others (i.e. let it act as an over-ride), and taggers should give the option of removing the user values from all (downloaded) files.
5. ReplayGain RealLife adjustment
The gain required to give the actual SPL of the original event (in a calibrated system), or a human judged sensible replay level (see the explanation behind the original "Audiophile" level and the work of Bob Katz if you think this is an impossible idea). I've found a few DVD-A discs that have this information (it's in the MLP stream), so it would be nice to have somewhere to store it. It's unlikely to get used much, but it would be a useful thing to have. It would be the last link in some of the best recordings out there.
I'd like to come to a consensus of which ones of these (if any/all) should be included, and then get some specs as to how they are/should be stored in each file format (especially APE2.0 tags) finalised and published on-line.
Comments? Suggestions? Offers of help?
btw I've received a couple of suggestions for improving the ReplayGain calculation. One is trivial, and seems like a great idea. I'll post it for testing when the problem of version numbering is solved. If anyone else has slightly or totally re-worked the ReplayGain algorithm/concept, now would be a good time to step forward! We could do listening tests to find the best candidate for "calculation version 2".
Newbie warning: this thread is not for asking questions about ReplayGain that are already answered on www.replaygain.org or in previous threads on HA. (I'm always happy to answer "silly" questions via email – half of them aren't silly at all.)
However, if you do already have some understanding of ReplayGain then this thread is the perfect place for clarifying anything to do with the above proposals which is not clear.
This post has been edited by 2Bdecided: Nov 18 2003, 17:42
Jan 8 2004, 20:31
Joined: 4-January 04
Member No.: 10938
QUOTE (2Bdecided @ Jan 8 2004, 06:03 PM)
I think you've got more time to write that I have to reply!
You don't need a genre or system gain.
well, personnally, I do
It really is the same thing as the "real life" replay gain you mention, whatever name we call it.
And to me replaygain is half useful without such a thing.
Before we store it, we add 6dB to each gain adjustment value, because that's what everyone has chosen to do.
and reading bob Katz, it's not really a surprise. Majoritiy of files come from pop CD which have been recorded with 6dBFS less headroom than the kind of material used for RP200 calibration. So this 6dB is not arbitrary, it's characteristic of a genre. Choosing a 'genre-shift' for each song on audio-engineer concerns has the same goal as knowing its real-life RG value - except you can have a try at it yourself.
That's why I suggested some kind of genre_shift tag. It could introduce RealLifeG in the files and at the same time solve the problem of both 83 / 89 distinct references in use around.
It seems you want to stick as much as possible to the original replaygain tag specs, and I was not planning on arguing to death for storing a precise set of value with a precise set of names, and introducing a "RealLifeRG" tag is just as good to me.
As for the discussion you started with yourself about album gain vs audiophile gain vs different things needing to sound a different loudness - I've been there, hence my suggestion for RealLife RG adjustment (see my very first post in this thread).
well yeah, and I'm all for that tag. But you don't suggest much about it.
Do you suggest it be restricted to real SPL measure data during real-life event ?
or possibly personnal estimation of appropriate Real life SPL would go there too ?
do you have something in mind so that it's still possible to tell the latter from the former ?
I'm thinking, if I store 89dB there when replaygain-computing my pop-songs, 83 for classical and maybe 93 for real heavy genres, I would still distinguish it from measured values like 83.46673 with a very, very good chance, and I could use some degree of 'reallife RG' feature now and for most my files, while I dont yet own a recording with reallife RG measures.
(that's the 'genre_shift' aspect of the tag I was debating about. probably more commonly useful than than its other, stricter-sense, aspect of real-recording-calibration-data tag)
|Lo-Fi Version||Time is now: 10th December 2013 - 00:31|