INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: Automatic Replay Gain Preamp (EXPLANATION)  (Read 5024 times)

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42373
  • Shoes gone again!
Automatic Replay Gain Preamp (EXPLANATION)
« on: December 06, 2002, 04:28:44 am »

The idea with the new "auto" replay gain mode is that each playlist is as loud as possible while being the same volume *inside* the playlist.  The volume *between* playlists will be very different.  (a playlist is any collection of tracks in Playing Now)

Here's a summary of the process:

FOR EACH FILE:

1) figure out how much we could safely turn a file up using the peak level
2) use (1) to see how much we could safely add to the replay gain level

Auto preamp will be the minimum (2) from all the files.

Example with 2 files

A: peak level: 50%, replay gain: -10 dB
B: peak level: 75%, replay gain: -4 dB

A(1) = 50% -> +6dB could be added safely
A(2) = +6dB - -10dB = 16 dB could be added to RG

B(1) = 75% -> +3dB could be added safely
B(2) = +3dB - -4dB = 7 dB could be added to RG

Auto preamp = min(A(2), B(2)) = +7 dB

During playback:

Actual gain (A) = -10 dB + 7 dB = -3 dB
Actual gain (B) = -4 dB + 7 dB = +3 dB

From Dragyn:

Quote
replay gain (auto, playlist based) isn't adjusting to 0dB. replay gain analyzes to the 1/100th (-11.85dB). dsp studio adjusts to the 1/10th, shows -11.9dB , adjusts +14.0dB, changes to +2.2dB instead of 0dB.


It won't, because it factors in the "peak level" and realizes that it could safely turn it up even more.  And internally we use lots of precision for replay gain, but round when displaying it.


Quote
Think of it as normalizing but using reply gain values. If I play each file one at a time in playing now, it will do exactly what I would like.


If you play just one file in "auto" mode, it just ends up "peak level" normalizing the file, and doesn't even use Replay Gain.  Replay Gain only kicks in if there are multiple files -- it makes sure they're all the same volume.

Hope that makes some sense...
Logged
Matt Ashland, JRiver Media Center

Charlemagne 8

  • Citizen of the Universe
  • *****
  • Posts: 1999
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #1 on: December 06, 2002, 05:05:51 pm »

I don't know "how", I only have a basic understanding of "why" but this works wonderfully. Thanks.
Very similar to the automatic equalizer idea of a while back (but never materialized).
CVIII
Logged
That's right.
I'm cool.

zevele10

  • Guest
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #2 on: December 07, 2002, 04:19:58 am »

Matt

Since a week running 9-and NOT thinking even a seconde to go back to 8,you gave us a total killer with MC9-
So running 9 with few thousands songs 'replay/gain' with 8 ,do automatic replay gain will work or ,do i need to 'replay/gain' the songs with 9?

In case of new imported songs ,do i need to 'replay/gain ' them before automatic replay gain works ?

Sorry about all the ?-i try to find out once for good

Keep the good job and thank you for MC9
Logged

MachineHead

  • Guest
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #3 on: December 07, 2002, 07:31:35 am »

Matt,

This works very well. Nice job. One curious thing I have noticed is some files I mp3Gained. They tend to play louder then the ones that I haven't done. Even though they should be quieter. Peak Level indicates some are as much as 40% different from non mp3Gained files. Not that it bugs me, just kind of an oddity. Maybe have to mess with them some more to see if it is just a few files, or all that had been altered.

Just to note, the files were all set to album gain at 89db.
Logged

dragyn

  • Guest
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #4 on: December 08, 2002, 02:44:08 am »

If rg doesn't apply for one song in a playlist and it just uses peak level, then I guess that's what I would want for multiple files aswell.

It just seems like the volume is too low. I use the audiophile 24/96 card and there's just preamp outputs on it.
Logged

zevele10

  • Guest
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #5 on: December 10, 2002, 11:24:56 am »

please ,do not forget me..........
try to answer me...
so many tracks that it is of some importance to me
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42373
  • Shoes gone again!
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #6 on: December 10, 2002, 12:06:38 pm »

If a file isn't analyzed, we use the average of all the analyzed files in the playlist as the replay gain for that file.  It's a guess, but usually better than nothing.

And with a lot of files, it can make things quiet -- usually from one or two oddballs. (where RG is like +5 dB but the peak level is already 100%)  We may make a better system for handling outliers.

Thanks.
Logged
Matt Ashland, JRiver Media Center

Marty3d

  • Citizen of the Universe
  • *****
  • Posts: 1363
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #7 on: December 10, 2002, 01:04:06 pm »

Matt,
As always, you've outdone yourself with another super cool feature! Thanks for your innovative thoughts :)

A question though: Is it right that with some files selected it becomes a quite loud output but with other not? The reason I ask is because I tried it some days ago and depending on which files I played I had to (in one case) run to the amplifier and turn it down...although I love music, my neighbours don't love it three o'clock in the morning :) So finally I changed the settings back to "normal"... But then again, I might have done something completely wrong.

Thanks!
/Martin
Logged


nila

  • Guest
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #8 on: December 10, 2002, 02:11:17 pm »

THANKS!!!

Noticed my files were playing REALLY quietly compared to other sounds on my computer. Started playing with this and when I turned it on my music suddenly became a lot louder.

Thanks :)
Logged

Doof

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 5908
  • Farm Animal Stupid
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #9 on: December 11, 2002, 05:02:04 am »

Is there anyway this could help out with the album gain problem?

I know I could always just turn replay gain off when I'm just playing one album, but it's really too much of a hassle to remember to do that every time, and nearly impossible when you're using a remote.
Logged

Matt

  • Administrator
  • Citizen of the Universe
  • *****
  • Posts: 42373
  • Shoes gone again!
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #10 on: December 11, 2002, 05:33:58 am »

Is there anyway this could help out with the album gain problem?

Depends what your goal is.  If you want all the tracks to sound the same volume and to be as loud as safely possible, then yes.  If you want to respect the (possibly intentional) between track volume differences of the mixing engineer, then no.

Is it right that with some files selected it becomes a quite loud output but with other not?

Yes.  Each playlist will be the same volume within the playlist.  However, the volume between playlists will be totally different.
Logged
Matt Ashland, JRiver Media Center

Doof

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 5908
  • Farm Animal Stupid
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #11 on: December 11, 2002, 06:35:25 am »

Yeah, I notice the replay gain problem primarily when listening to an album that has tracks that run into each other. There will suddenly be an artificial jump in volume when it changes track.

Any chance we'll see an option for MJ to automatically detect that all files in the playlist are the same album and automatically disable replay gain? Even better would be if it noticed multiple albums in the playlist, but all sequential track numbers and automatically adjusted the volume so that the loudest track from each album played at the same volume, and all other tracks from those albums scaled appropriately to those loudest tracks. So essentially, all albums play no louder than each other, but within the album, individual tracks honor the intential volume changes from track to track.

I think I'm getting worse at describing what I'm thinking. :P
Logged

zevele10

  • Guest
Re: Automatic Replay Gain Preamp (EXPLANATION)
« Reply #12 on: December 11, 2002, 07:06:12 am »

concerning the album problem,i am with Doof.
Maybe if from the tree a full album to play,in this case the replay gain swicht of.
Do not know if such a thing possible.
Doof ,i have the opposite problem than you.
Most of the time i play full albums so i have replay gain of as default and when i play a playlist i forget to put it on-of cause...-
I remember to do so AFTER my first jump from my chair
Logged
Pages: [1]   Go Up