kmix DCOP call return values wrong?
David Jarvie
software at astrojar.org.uk
Thu Feb 24 19:33:21 GMT 2005
On Thursday 24 Feb 2005 16:02, Christian Esken wrote:
> Am Montag, 21. Februar 2005 01:00 schrieb David Jarvie:
> > This does raise the issue for KAlarm as to how to ensure that it is able
> > to set the volume when playing sound. It tries to set the absolute volume
> > (i.e. independently of the current master volume setting (or however the
> > general sound level is set if master volume isn't available)), so that
> > the sound level is predictable for the alarm even if the user has changed
> > the system's volume setting between setting up the alarm and it being
> > triggered. (Some people use it to wake themselves up in the morning, for
> > example.). Is there any reliable way of setting the absolute volume
> > regardless of whether ALSA, OSS, etc is used, and regardless of whether
> > the master volume exists? Ideally
>
> This is an easy answer: No.
>
> Because you cannot know, what controls (and how many controls) you have to
> regulate.
>
> For example, lets assume you want to change the "WAV" or "MP3" playback
> volume to a reliable, reproducable level on my Soundcard. That's easy,
> isn't it? Well ...
> You will at least need to set Master, PCM and DAC. Also it wouldn't be a
> bad idea to check on the Record-Monitor stuff, because if you currently
> have configured your soundcard for being able to capture PCM data, you
> might also hear that in the output (worst case: you get a feedback loop,
> which will wake you up very quickly).
>
> Making it even more complicated: "Master" is no real Master in ALSA.
> Actually it only regulates "Front". So you might also need to control
> "Surround", "Center" and probably set some switches.
>
> Making it easier: If you assume, that "most" controls have sensible values,
> you should be quite safe, when if you regulate "PCM" and/or "Master/Front"
> and "Surround".
>
> > I'd like to do it via library calls instead of calling kmix which isn't
> > guaranteed to be installed.
>
> Then you need to use ALSALIB and/or the OSS-API and/or the Solaris-API
> and/or the SGI-API, ... There is no other good way that I am aware of.
>
> You might try your luck with some of the Game API's, but nobody will
> guarantee you that those are intalled - so I would recommend not to try
> that.
Thanks for that explanation - I feared that that might be the answer. But at
least it's a lot clearer now.
Cheers,
David.
More information about the kde-multimedia
mailing list