mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-01 22:58:50 -04:00
stream: somewhat implement drain better
Abuse the xrun callback in the adapter to emit the drained signal until almost all data left the resampler. This needs more work with a proper signal and a buffer flag to signal the drain.
This commit is contained in:
parent
ce39c6200d
commit
22e590c7cc
3 changed files with 25 additions and 7 deletions
|
|
@ -886,8 +886,10 @@ static int impl_node_process(void *object)
|
|||
|
||||
if (status & SPA_STATUS_NEED_DATA) {
|
||||
status = spa_node_process(this->follower);
|
||||
if (!(status & SPA_STATUS_HAVE_DATA))
|
||||
if (!(status & SPA_STATUS_HAVE_DATA)) {
|
||||
spa_node_call_xrun(&this->callbacks, 0, 0, NULL);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue