[pulseaudio-discuss] Volume algorithm

Colin Guthrie gmane at colin.guthr.ie
Sat Mar 5 03:08:21 PST 2011


'Twas brillig, and Tarantism at 04/03/11 22:23 did gyre and gimble:
> I need to implement a volume scaling in a pulse module.
> I have 0-100 input values.
> What algorithm does pulse usually implement for this so that I can match
> it?

Can you explain a little more what you're trying to do? You shouldn't
generally need to worry about volume scaling in PA modules.

But ultimately PA scales volumes between PA_VOLUME_MIN (aka 0%, aka -inf
dB) and PA_VOLUME_NORM (aka 100%, aka 0dB) typically, but really the
upper volume is PA_VOLUME_MAX (aka Lots%, aka +Lots dB).

But if you explain in a bit more detail we can probably advise you
better. I don't think you'll need to do any specific volume handling
unless you are writing a very specific module.

Col


-- 

Colin Guthrie
gmane(at)colin.guthr.ie
http://colin.guthr.ie/

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mageia Contributor [http://www.mageia.org/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]




More information about the pulseaudio-discuss mailing list