Re: Volume confusion

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



jon wrote:
>     snd_mixer_selem_get_playback_volume_range(elem, &min, &max);
>     vpercent = (float)volume/100;
>     fnewvol = (float)min + vpercent * ( (float)max - (float)min);
>     newvol = (long)fnewvol;
>     if ( snd_mixer_selem_set_playback_volume_all(elem,newvol) <0)

This is correct.  (Although the steps will not appear to have the
same volume differnce; you should use the dB functions, if possible.)


Regards,
Clemens

------------------------------------------------------------------------------
Precog is a next-generation analytics platform capable of advanced
analytics on semi-structured data. The platform includes APIs for building
apps and a phenomenal toolset for data science. Developers can use
our toolset for easy data analysis & visualization. Get a free account!
http://www2.precog.com/precogplatform/slashdotnewsletter
_______________________________________________
Alsa-user mailing list
Alsa-user@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/alsa-user




[Index of Archives]     [ALSA Devel]     [Linux Audio Users]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]

  Powered by Linux