|
|
@ -266,19 +266,20 @@ void SinkStream::ProcessAudioOutAndRender(std::span<s16> output_buffer, std::siz
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void SinkStream::Stall() {
|
|
|
|
void SinkStream::Stall() {
|
|
|
|
if (stalled) {
|
|
|
|
std::scoped_lock lk{stall_guard};
|
|
|
|
|
|
|
|
if (stalled_lock) {
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
stalled = true;
|
|
|
|
stalled_lock = system.StallProcesses();
|
|
|
|
system.StallProcesses();
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
void SinkStream::Unstall() {
|
|
|
|
void SinkStream::Unstall() {
|
|
|
|
if (!stalled) {
|
|
|
|
std::scoped_lock lk{stall_guard};
|
|
|
|
|
|
|
|
if (!stalled_lock) {
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
system.UnstallProcesses();
|
|
|
|
system.UnstallProcesses();
|
|
|
|
stalled = false;
|
|
|
|
stalled_lock.unlock();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
} // namespace AudioCore::Sink
|
|
|
|
} // namespace AudioCore::Sink
|
|
|
|