mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-25 06:59:57 -05:00
rt-poll: make small poll helper object
Remove the event loop code into a separate object so that we can share the same loop for multiple nodes. Some cleanups
This commit is contained in:
parent
b9409e297b
commit
7b53fa8685
11 changed files with 517 additions and 239 deletions
|
|
@ -43,8 +43,6 @@ typedef struct {
|
|||
* @user_data: user data
|
||||
* @fds: array of file descriptors
|
||||
* @n_fds: number of elements in @fds
|
||||
* @now: the current time
|
||||
* @timeout: the next desired wakeup time relative to @now
|
||||
*
|
||||
* Data passed to #SpaPollNotify.
|
||||
*/
|
||||
|
|
@ -52,8 +50,6 @@ typedef struct {
|
|||
void *user_data;
|
||||
SpaPollFd *fds;
|
||||
unsigned int n_fds;
|
||||
uint64_t now;
|
||||
uint64_t timeout;
|
||||
} SpaPollNotifyData;
|
||||
|
||||
typedef int (*SpaPollNotify) (SpaPollNotifyData *data);
|
||||
|
|
@ -67,7 +63,7 @@ typedef int (*SpaPollNotify) (SpaPollNotifyData *data);
|
|||
* @idle_cb: callback called when there is no other work
|
||||
* @before_cb: callback called before starting the poll
|
||||
* @after_cb: callback called after the poll loop
|
||||
* @user_data: user data pass to callbacks
|
||||
* @user_data: user data passed to callbacks
|
||||
*/
|
||||
typedef struct {
|
||||
uint32_t id;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue