Server-side corking

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

 



On 04/30/2013 01:05 PM, Tanu Kaskinen wrote:
> Hi all,
>
> Tizen has a patch[1] that makes it possible to cork streams from the
> server side. So far only applications have been allowed to cork streams
> (it has been possible to cork streams also from the server side, but
> that would cause conflicts if both applications and the server want to
> cork and uncork the same streams).
>
> I'm not familiar with the use case that has inspired the patch (Jaska or
> Janos, it would be nice if you could explain the use case), but in
> general server-side corking sounds sensible to me. The particular
> implementation of the patch doesn't look so good to me, though: it just
> adds one boolean to pa_sink_input for any server-side corking (the
> feature doesn't seem to have been added to source outputs at all). There
> may be multiple modules doing corking, so having just one boolean will
> still be prone to conflicts.
>
> I propose that we add a hashmap/list/whatever for cork requests, so that
> there can be any number of simultaneous requests for one stream, and the
> stream will stay corked as long as there is at least one request. When a
> client requests corking, a cork request object will be created and
> associated with the client, and the cork request object will be removed
> when the client request uncorking. Similarly, modules would be able to
> create and manage their own cork request objects.
>
> Comments would be very welcome. If there is no opposition, this feature
> will probably implemented sooner or later (I doubt that Tizen wants to
> carry that patch forever).
>
> [1] https://github.com/otcshare/pulseaudio/commit/f60d68bb1fc8e3b746d467d0638f522c4795229a
>

I'm not sure a hashmap/list of cork requests is the best. I guess this 
could depend on *why* you want to cork the stream - I believe 
module-role-cork (which pauses music on phone calls), would pause the 
stream even on the client side, making it possible for the user to 
override by pressing "play" in his music player. This seems useful to me.

-- 
David Henningsson, Canonical Ltd.
https://launchpad.net/~diwic


[Index of Archives]     [Linux Audio Users]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux