output/PipeWire: activate stream in Drain()
This commit is contained in:
parent
bc6924d303
commit
6b430ba271
1
NEWS
1
NEWS
|
@ -5,6 +5,7 @@ ver 0.23.8 (not yet released)
|
||||||
- cdio_paranoia: fix crash if no drive was found
|
- cdio_paranoia: fix crash if no drive was found
|
||||||
- cdio_paranoia: faster cancellation
|
- cdio_paranoia: faster cancellation
|
||||||
- cdio_paranoia: don't scan for replay gain tags
|
- cdio_paranoia: don't scan for replay gain tags
|
||||||
|
- pipewire: fix playback of very short tracks
|
||||||
- snapcast: fix busy loop while paused
|
- snapcast: fix busy loop while paused
|
||||||
- snapcast: fix stuttering after resuming playback
|
- snapcast: fix stuttering after resuming playback
|
||||||
* mixer
|
* mixer
|
||||||
|
|
|
@ -866,6 +866,17 @@ PipeWireOutput::Drain()
|
||||||
{
|
{
|
||||||
const PipeWire::ThreadLoopLock lock(thread_loop);
|
const PipeWire::ThreadLoopLock lock(thread_loop);
|
||||||
|
|
||||||
|
if (drained)
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (!active) {
|
||||||
|
/* there is data in the ring_buffer, but the stream is
|
||||||
|
not yet active; activate it now to ensure it is
|
||||||
|
played before this method returns */
|
||||||
|
active = true;
|
||||||
|
pw_stream_set_active(stream, true);
|
||||||
|
}
|
||||||
|
|
||||||
drain_requested = true;
|
drain_requested = true;
|
||||||
AtScopeExit(this) { drain_requested = false; };
|
AtScopeExit(this) { drain_requested = false; };
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue