Improve upload

Only send a buffer when we have received a NEED_DATA message.
Add a signal to pulla buffer from the sink. Restructure the sink to use
a queue like the source and only push a buffer when we can.
Improve SpaData. Offset and size should be between 0 and maxsize, make
sure we clamp correctly when needed.
node_process_output completes the processing of the output after
receiving HAVE_OUTPUT for async elements. It instructs the node that
it now can produce more output.
This commit is contained in:
Wim Taymans 2016-12-20 16:51:57 +01:00
parent 8ce3f949e2
commit 5b0b9c43d0
18 changed files with 201 additions and 112 deletions

View file

@ -196,11 +196,11 @@ spa_debug_buffer (const SpaBuffer *buffer)
fprintf (stderr, " flags: %d\n", d->flags);
fprintf (stderr, " data: %p\n", d->data);
fprintf (stderr, " fd: %d\n", d->fd);
fprintf (stderr, " offset: %zd\n", d->offset);
fprintf (stderr, " maxsize: %zd\n", d->size);
fprintf (stderr, " offset: %zd\n", d->mapoffset);
fprintf (stderr, " maxsize: %zu\n", d->maxsize);
fprintf (stderr, " chunk: %p\n", d->chunk);
fprintf (stderr, " offset: %zd\n", d->chunk->offset);
fprintf (stderr, " size: %zd\n", d->chunk->size);
fprintf (stderr, " size: %zu\n", d->chunk->size);
fprintf (stderr, " stride: %zd\n", d->chunk->stride);
}
return SPA_RESULT_OK;