mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-02 09:01:50 -05:00
audioadapter: loop until we have data
Keep caling the slave processing function until we have data from the converter or until no process can be made.
This commit is contained in:
parent
58a7e18ed5
commit
d67d012362
2 changed files with 11 additions and 4 deletions
|
|
@ -875,12 +875,19 @@ static int impl_node_process(void *object)
|
|||
status = spa_node_process(this->convert);
|
||||
}
|
||||
|
||||
again:
|
||||
status = spa_node_process(this->slave);
|
||||
|
||||
if (this->direction == SPA_DIRECTION_OUTPUT && !this->master) {
|
||||
if (this->use_converter)
|
||||
status = spa_node_process(this->convert);
|
||||
if (this->direction == SPA_DIRECTION_OUTPUT &&
|
||||
!this->master && this->use_converter) {
|
||||
status = spa_node_process(this->convert);
|
||||
|
||||
if (!(status & SPA_STATUS_HAVE_DATA) &&
|
||||
(status & SPA_STATUS_NEED_DATA))
|
||||
goto again;
|
||||
}
|
||||
spa_log_trace_fp(this->log, "%p: process status:%d", this, status);
|
||||
|
||||
this->master = false;
|
||||
|
||||
return status;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue