Signal buffer event on audio in/out system stop, and force remove all registered audio buffers

This commit is contained in:
Kelebek1
2022-12-16 16:01:35 +00:00
parent 9ff891ce71
commit 6a56f42f5d
5 changed files with 26 additions and 7 deletions

View File

@ -73,6 +73,12 @@ void DeviceSession::Stop() {
}
}
void DeviceSession::ClearBuffers() {
if (stream) {
stream->ClearQueue();
}
}
void DeviceSession::AppendBuffers(std::span<const AudioBuffer> buffers) const {
for (const auto& buffer : buffers) {
Sink::SinkBuffer new_buffer{