mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-01 22:58:50 -04:00
Make PinosPort struct
Keep track of the ports, their links and the allocated buffers in a small struct managed by the node.
This commit is contained in:
parent
c6861845a7
commit
fe37e2bc1b
4 changed files with 364 additions and 417 deletions
|
|
@ -40,6 +40,14 @@ typedef struct _PinosLinkPrivate PinosLinkPrivate;
|
|||
#define PINOS_LINK_CAST(obj) ((PinosLink*)(obj))
|
||||
#define PINOS_LINK_CLASS_CAST(klass)((PinosLinkClass*)(klass))
|
||||
|
||||
typedef struct {
|
||||
PinosNode *node;
|
||||
uint32_t port;
|
||||
gboolean allocated;
|
||||
SpaBuffer *buffers[16];
|
||||
guint n_buffers;
|
||||
} PinosPort;
|
||||
|
||||
/**
|
||||
* PinosLink:
|
||||
*
|
||||
|
|
@ -48,12 +56,8 @@ typedef struct _PinosLinkPrivate PinosLinkPrivate;
|
|||
struct _PinosLink {
|
||||
GObject object;
|
||||
|
||||
PinosNode *output_node;
|
||||
guint output_id;
|
||||
uint32_t output_port;
|
||||
PinosNode *input_node;
|
||||
guint input_id;
|
||||
uint32_t input_port;
|
||||
PinosPort *output;
|
||||
PinosPort *input;
|
||||
|
||||
uint32_t queue[16];
|
||||
SpaRingbuffer ringbuffer;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue