mem: remove memory stuff

Remove the memory stuff from the spa API, we can do thing more simple
and efficiently if we always allocate buffers outside of the plugins and
only implement an alloc function on the node when it can do something
clever.
Move serialize code to the props/format/buffer code
Make it possible to copy a format and properties.
This commit is contained in:
Wim Taymans 2016-09-29 18:18:59 +02:00
parent fe37e2bc1b
commit 24108e01c1
46 changed files with 901 additions and 1546 deletions

View file

@ -309,7 +309,7 @@ mmap_read (SpaALSAState *state)
SpaALSABuffer *b;
snd_htimestamp_t htstamp = { 0, 0 };
int64_t now;
uint8_t *dest;
uint8_t *dest = NULL;
snd_pcm_status_alloca(&status);
@ -374,8 +374,8 @@ mmap_read (SpaALSAState *state)
SpaNodeEventHaveOutput ho;
SpaData *d;
d = SPA_BUFFER_DATAS (b->outbuf);
d[0].mem.size = avail * state->frame_size;
d = b->outbuf->datas;
d[0].size = avail * state->frame_size;
b->next = NULL;
SPA_QUEUE_PUSH_TAIL (&state->ready, SpaALSABuffer, next, b);