mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-12-16 08:56:45 -05:00
Improve memory handling
Reserve 0,0 for stack allocated mem that we never free Improve allocation in the link Parse format and properties in-line, there is no need to allocate memory. Improve buffer cleanup in alsa Add timestamps and offset to alsa
This commit is contained in:
parent
77f93e37ed
commit
27acab7532
7 changed files with 155 additions and 69 deletions
|
|
@ -52,6 +52,7 @@ struct _SpaALSABuffer {
|
|||
SpaMetaRingbuffer ringbuffer;
|
||||
SpaData datas[1];
|
||||
SpaBuffer *outbuf;
|
||||
SpaMetaHeader *h;
|
||||
void *ptr;
|
||||
bool outstanding;
|
||||
SpaALSABuffer *next;
|
||||
|
|
@ -89,7 +90,6 @@ struct _SpaALSAState {
|
|||
SpaPortStatus status;
|
||||
|
||||
bool have_buffers;
|
||||
|
||||
SpaMemory *alloc_bufmem;
|
||||
SpaMemory *alloc_mem;
|
||||
SpaALSABuffer *alloc_buffers;
|
||||
|
|
@ -102,6 +102,7 @@ struct _SpaALSAState {
|
|||
SpaPollFd fds[16];
|
||||
SpaPollItem poll;
|
||||
|
||||
int64_t sample_count;
|
||||
int64_t last_ticks;
|
||||
int64_t last_monotonic;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue