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

Reimar Döffinger Reimar.Doeffinger at stud.uni-karlsruhe.de
Fri Nov 5 17:14:48 CET 2004


On Fri, Nov 05, 2004 at 01:14:19PM -0500, The Wanderer wrote:
> Oded Shimon wrote:
> 
> >On Friday 05 November 2004 18:11, Torinthiel wrote:
> >
> >>Have you read it? Or have you read the code and here is wrong? I
> >>see the range is 50-200. How is 90 close to 200? If you want it
> >>neat the middle of scale, which I find reasonable, then 90 is
> >>better then 50, and 100 would be even better. Or the code accepts
> >>50-100, and 200 in manpage patch is a mistake.
> >
> >You misunderstood the code.
> 
> Nonetheless, I don't remember if I'd read the code (I have now, and it
> looks comparatively simple; I don't even see where or how the 50 and 200
> values are coded), and had misread even the man-page description; I was
> operating with a working assuption of 100 as max (and that raising the
> number would have no effect on the present volume, but only on the range
> within which one can change the volume). 100l-or-so equivalent to me for
> that, unless I'm now misunderstanding things even worse, but now I'm not
> sure I *do* understand things, because if the situation as I now think I
> understand it is correct then I don't know how my previous objections
> could have failed to be reacted to as quite plainly insane.

The -vol-normal parameter does not change the volume, it changes the
range in which you can change it. The range limits of 10 and 200 are
actually arbitrary, only e.g. 0 zero must not be allowed (division by zero
is bad ;-) ).
As also mentioned in the manpage part of my updated patch, values above
100 can cause weird behavior, because MPlayer then is told that the
current volume was e.g. 200%, and upon changing the volume it will
always drop into the right range...
In principle MPlayers 0% - 100% range of volume is mapped to a 0% -
100/softvol-norm% range for the real volume change.

Greetings,
Reimar Döffinger




More information about the MPlayer-dev-eng mailing list