[pulseaudio-discuss] Event subscription questions

Colin Guthrie gmane at colin.guthr.ie
Wed Jan 27 11:27:15 PST 2010


'Twas brillig, and Forwind info at 27/01/10 19:08 did gyre and gimble:
> Hi all,
> 
> I'm building a client app using the async api. For now I have subscribed
> to two events PA_SUBSCRIPTION_EVENT_SINK and
>  PA_SUBSCRIPTION_EVENT_SINK_INPUT.  i noticed one cancels the other out ?
> 
> i.e. if i subscribe to the straight sink_event after subscribing to
> sink_input I don't get any notification of the sink_input only generic
> sink event notifications .  Similarly if I subscribe to the sink_input
> after the subscribing to sink_events i don't get any sink_event
> notifications. I'm a missing something here ?

You should only call the subscribe function once, passing in a "bitwise
or" of all the events you want to subscribe to.

e.g.:
http://colin.guthr.ie/git/kdemultimedia/tree/kmix/mixer_pulse.cpp?h=pulse#n554

HTHs

Col

-- 

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

Day Job:
  Tribalogic Limited [http://www.tribalogic.net/]
Open Source:
  Mandriva Linux Contributor [http://www.mandriva.com/]
  PulseAudio Hacker [http://www.pulseaudio.org/]
  Trac Hacker [http://trac.edgewall.org/]




More information about the pulseaudio-discuss mailing list