[pulseaudio-discuss] Jack detection - Client API for UIs
gmane at colin.guthr.ie
Mon Nov 14 11:56:07 PST 2011
'Twas brillig, and David Henningsson at 14/11/11 10:22 did gyre and gimble:
> On 11/11/2011 03:08 PM, David Henningsson wrote:
>> On 11/11/2011 12:17 AM, David Henningsson wrote:
>>> Do you think we can merge these different views and come up with an
>>> agreed client API within a couple of days?
>> Ok, so I can happily say that we had a great IRC conversation on the
>> topic today. The outcome was:
>> * Not to register port objects with the core (for the time being)
>> * Not to add "inactive" sinks/sources to the client API (for the time
>> * When port availability changes, fire a subscription event for the card.
>> * I'm not sure we got consensus on if/when the sink/source should also
>> get a subscription event, but that can be discussed later.
>> * To change the existing proposal's "is_input" and "is_output" to a
>> bitfield. Thus the new client API proposal is now attached. I'll start
>> working on implementing this next week unless I hear massive complaints.
>> One detail though: should the enums be declared as is (e g
>> "pa_direction_t direction;") or as ints ("int direction;")? I remember
>> someone saying enums were more likely to change size than ints.
> In line with the client API proposal, here's the matching protocol
> Any objections?
> ## v25, implemented by >= 2.0
> When port availability changes, send a subscription event for the
> owning card.
> ## v26, implemented by >= 2.0
> In reply from PA_COMMAND_GET_CARD_INFO (and thus
> PA_COMMAND_GET_CARD_INFO_LIST), the following is added:
> uint32_t n_ports
> ....followed by n_ports extended port entries, which look like this:
> string name
> string description
> uint32_t priority
> uint32_t available
Can we make this a uint8_t? I know the protocol might send a uint32_t
for availability elsewhere but there is no reason for this to be carried
through where it's not needed.
> uint8_t direction
> uint32_t n_profiles
> string profile_name_1
> string profile_name_n
> Profile names must match earlier sent profile names for the same card.
Can we get an icon in here somehow? IMO each port should have it's own
icon to allow for Speakers to be presented differently in UIs to Headphones.
More information about the pulseaudio-discuss