Rockbox.org home
Downloads
Release release
Dev builds dev builds
Extras extras
themes themes
Documentation
Manual manual
Wiki wiki
Device Status device status
Support
Forums forums
Mailing lists mailing lists
IRC IRC
Development
Bugs bugs
Patches patches
Dev Guide dev guide
Search



Donate

Rockbox Technical Forums


Login with username, password and session length
Home Help Search Staff List Login Register
News:

Welcome to the Rockbox Technical Forums!

+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  Feature Ideas
| | |-+  Alternative for level matching non replaygain tracks. (or replaygain via volume)
« previous next »
  • Print
Pages: [1]

Author Topic: Alternative for level matching non replaygain tracks. (or replaygain via volume)  (Read 1966 times)

Offline nwimpney

  • Member
  • *
  • Posts: 5
Alternative for level matching non replaygain tracks. (or replaygain via volume)
« on: July 15, 2010, 02:54:56 PM »
There's currently a pre-gain for level matching replaygain tracks to other tracks, but it seems this would often cause clipping, right?

Would it not make sense to have an option to attenuate non-replaygain files by a set amount?

This would have the same effect, except without the possibility of clipping.

Of course, if replaygain is implemented through the volume control (It probably should be), it probably doesn't matter from a clipping perspective, and would be moot, except at the extremes of the volume settings.  Is this the case, or is it done by scaling the samples? 

I know I saw it mentioned in the battery life faq that it does sample scaling, but that seems a little silly to me, so maybe it's been changed.

-Nick
Logged

Offline Chronon

  • Rockbox Expert
  • Member
  • *
  • Posts: 4379
Re: Alternative for level matching non replaygain tracks. (or replaygain via volume)
« Reply #1 on: July 16, 2010, 05:00:29 AM »
I have never seen a ReplayGain  with positive gain adjustment.  Many modern tracks have ReplayGain adjustments close to -10dB
Logged
Sansa e280, Gigabeat F40, Gigabeat S60, Sansa Clip+, iPod Mini 2g

Offline saratoga

  • Developer
  • Member
  • *
  • Posts: 8974
Re: Alternative for level matching non replaygain tracks. (or replaygain via volume)
« Reply #2 on: July 16, 2010, 10:09:47 AM »
Quote from: nwimpney on July 15, 2010, 02:54:56 PM
There's currently a pre-gain for level matching replaygain tracks to other tracks, but it seems this would often cause clipping, right?

Theres basically no way you'd get clipping if you're using it correctly.

Quote from: nwimpney on July 15, 2010, 02:54:56 PM
Would it not make sense to have an option to attenuate non-replaygain files by a set amount?

This has been discussed and we're generally in favor of it.

Quote from: nwimpney on July 15, 2010, 02:54:56 PM
Of course, if replaygain is implemented through the volume control (It probably should be),

Its not done through volume control for several reasons:

1)  It can't be done through volume control because theres no way to exactly synchronize changes to the output amplifier gain with track boundaries. 

2)  The volume control has suboptimal resolution on many devices (1-1.5dB is typical).

3)  Applying analog gain would increase clipping when decoding near maximum volume mp3 files.  The audibility of this is debatable, but its still an obvious drawback.
Logged

Offline nwimpney

  • Member
  • *
  • Posts: 5
Re: Alternative for level matching non replaygain tracks. (or replaygain via volume)
« Reply #3 on: July 16, 2010, 03:48:10 PM »
Quote from: saratoga on July 16, 2010, 10:09:47 AM
Theres basically no way you'd get clipping if you're using it correctly.

Okay.  I was just thinking that pre-gaining the replay gained tracks back up to a level where they match most other "loudness war" style tracks, would give too much gain on ones that are already at an appropriate level, but with a wide dynamic range.

For example.  Most songs tend to have about 8dB or more of reduction through replaygain, so setting the pre-gain to 8db would make them sound around the same level.  (along with ones with a more common 9-10 dB )
If I applied that same 8dB of pre-gain to a track that was already near reference level (say 3dB or so) I'm getting a potential of 5dB of clipping assuming the track has very high peaks compared to its average level.

This probably doesn't happen all that much in practice, and doing 5-6dB would probably give you enough headroom, while bringing your replay gain tracks up sort of close, though still noticably quieter. 

Quote
This has been discussed and we're generally in favor of it.
Cool.  I eagerly await this functionality. :D

Quote

Its not done through volume control for several reasons:

1)  It can't be done through volume control because theres no way to exactly synchronize changes to the output amplifier gain with track boundaries. 

2)  The volume control has suboptimal resolution on many devices (1-1.5dB is typical).

3)  Applying analog gain would increase clipping when decoding near maximum volume mp3 files.  The audibility of this is debatable, but its still an obvious drawback.

Yeah.  That makes sense.

#1 I guess would mostly be a problem mostly with gapless tracks with content right at the start/end.

#2 Is the dealbreaker I guess.  1dB doesn't seem like a huge problem, but I guess some players are a fair bit wider (or aren't on a proper log scale at all) :(

#3 I guess it's pretty academic due to #2,  but I don't really see where you'll get any additional clipping.
The only situation where I could see it being a problem is where you're applying a positive replay gain to quiet tracks with large peaks, and run into the analog limit of the amp.   Seems like a bit of a stretch, not that it really matters, since there's not precise enough control to do it anyways.  :-\

Logged

  • Print
Pages: [1]
« previous next »
+  Rockbox Technical Forums
|-+  Rockbox Development
| |-+  Feature Ideas
| | |-+  Alternative for level matching non replaygain tracks. (or replaygain via volume)
 

  • SMF 2.0.17 | SMF © 2019, Simple Machines
  • Rockbox Privacy Policy
  • XHTML
  • RSS
  • WAP2

Page created in 0.074 seconds with 15 queries.