[MPlayer-dev-eng] [PATCH] forceable software volume control

D Richard Felker III dalias at aerifal.cx
Sun Nov 14 02:49:52 CET 2004


On Sun, Nov 14, 2004 at 12:07:04AM +0000, Ed Wildgoose wrote:
> 
> >>>no, not at all. 2x greater is barely any change at all. it's the same
> >>>as a couple clicks on a soundsystem that goes by a decibel scale. 10x
> >>>is the very minimum cap that would be acceptible. but again it should
> >>>all be done in decibels since linear scales don't make sense to use
> >>>for signals.
> >>>     
> >>>
> >>This just does not work as easy as that in the digital case. Amplifying
> >>2x means you need one extra bit, for 8x amplification you need 3 extra
> >>bits. So without changing the format (hard to do as often both source
> >>and soundcard want 16 bit), this will only work when whoever created the
> >>file wasted at least 3 bits out of 16 by not adjusting the volume
> >>correctly. I am not convinced that adjusting to such crap is a good
> >>idea.
> >>   
> >>
> >
> >usually studios mastering dvd wasted 5-6 out of 16 bits... :(
> > 
> >
> 
> x2 is a 6dB increase, which is reasonably substantial actually. 
> 
> I do in fact have this very issue of having DVD's a little too quiet in 
> general, and in my case I have only a passive volume control on my hifi 
> (ie a variable resistor, not a pre-amp), so I have a limited volume 
> adjustment range.  Also, it's annoying having my music player blaring 
> because music is always mastered to clip (modern stuff), and then 
> switching to the DVD's player and having it almost inaudible (DVD's tend 
> to preserve a little dynamic range...)
> 
> However, having done a little bit of research most of my DVD's do in 
> fact turn out to have dynamic range which uses most of the 16 bits.  
> True the average sound level is quite far off maximum (although I can't 
> quickly find one that's 30dB down like you suggest - 15dB is more like 
> it), but the peak levels are often -3dB from max.
> 
> I used to set something like "-af volume:10", but now I realise that I 
> am just clipping the loud scenes for the sake of increasing the average 
> levels a little.

sometimes you have no choice. normally these peaks are rare annoying
sounds like gunshots/crashes/explosions, and i would actually _like_
them to clip. yes it sounds bad, but it's better than the alternative
of having them blow out my ears because i had to turn the hardware
volume control all the way up to even halfway be able to hear people's
voices...

> Personally I would be suprised if a +6 or +12dB increase wasnt actually 
> more than enough extra volume range for 95% of practical purposes?  For 
> the odd DVD which is really mastered that quietly you would at least get 
> it up to listenable volumes..?

in fact it's not ok for 95% of practical purposes, but that doesn't
really matter. the point is that the full range should be available,
all the way from making the loudest possible sounds inaudible to
making white noise blaring.

> I do agree that using a dB scale everywhere is a nice idea in theory, 
> but it needs a careful implementation in practice.  I talked the 
> bio2jack author into adding such a volume control to his Jack output 
> layer and he immediately found that his volume control in XMMS then 
> became just far too sensitive when trying to slide it a little with the 
> mouse.  The linear was better in practice because he could get some 
> control where it was needed, but still turn it really low if required.  
> I guess a kind of "half" log measure would be ideal...  Perhaps less of 

wtf? half log? no, just use a smaller scale, e.g. 0.5 or 0.25 dB
instead of 1 dB at a time. but i really doubt that's necessary..

rich




More information about the MPlayer-dev-eng mailing list