This is the bug/patch tracker for Rockbox. Click here for more information.
Quick links: Bugs · Patches · Rockbox frontpage
FS#7747 - (limited) replaygain for archos recorder
Attached to Project:
Rockbox
Opened by Christian Marg (einhirn) - Monday, 10 September 2007, 19:30 GMT+2
Last edited by Frank Gevaerts (fg) - Sunday, 05 June 2011, 00:26 GMT+2
Opened by Christian Marg (einhirn) - Monday, 10 September 2007, 19:30 GMT+2
Last edited by Frank Gevaerts (fg) - Sunday, 05 June 2011, 00:26 GMT+2
|
DetailsI've hacked up (limited) replaygain support for my archos recorder using the MAS digital volume control matrix.
Limits: - The overall (Track/Albumgain and Preamp) maximum "gain" is about +18dB - The "Prevent Clipping" option does nothing Cause for the limits: The MAS DVCM can only be used to attenuate, so there shouldn't be any clipping to prevent. Also, to simulate gain, I have set the +0dB (don't apply replaygain) mark to -18dB... I'm not sure if the Settings are correctly applied on Boot - the code says "they should", but I couldn't verify it. To do: - The replaygain settings of the new track are applied when it's about to be sent to the MAS, not when the MAS will actually play it. So there could be a split second (depending on the mp3 bitrate) at the end of the current track played with replaygain settings of the next track. - The analog amp in the recorder should have +5.95dB gain available somewhere, that would improve the chance to compensate for the "new 0dB" point. |
This task depends upon
Removed "Language file updates" - the updates removed a restriction on language files for the Noclip option.
Reworked preprocessor directives so that this replaygain support is only built on hw-codec-platforms
Modified the application of replaygain to use 64-Bit Multiplication less often. I've replaced it with Bitshifts and Binary operations where I could.
Found out, that the new MAS Replaygain settings are usually applied some fractions of a second into the _next_ track, so that switching from a silent track to a loud track will play a little bit of the Loud piece at a great volume and then lower the volume to the replaygain set value...
For my part the analog amp doesn't need to be cranked up, I can manage with what it does...
As amiconn states in http://www.rockbox.org/irc/reader.pl?date=20080130 the audible delay in applying replaygain settings probably occurs when a track change happens during rebuffering. In that case the MPEG-thread is busy with bit-swapping the data for the MAS - the bit-swapping can take up to ~65ms, add other delays and you have the audible volume change happening maybe 100-200ms into the new track.
I'll experiment with pushing the analog output, but clipping is possible with it - I'd like to avoid that...
Since I've yet to experiment with analog output and still have to see if replaygain gets updated correctly in "all" cases, this probably won't be the last comment here.