2019-12-23 07:02:11 +00:00
|
|
|
#include "null_audio_stream.h"
|
|
|
|
|
|
|
|
NullAudioStream::NullAudioStream() = default;
|
|
|
|
|
|
|
|
NullAudioStream::~NullAudioStream() = default;
|
|
|
|
|
|
|
|
bool NullAudioStream::OpenDevice()
|
|
|
|
{
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
|
|
|
|
void NullAudioStream::PauseDevice(bool paused) {}
|
|
|
|
|
|
|
|
void NullAudioStream::CloseDevice() {}
|
|
|
|
|
2020-06-06 04:40:20 +00:00
|
|
|
void NullAudioStream::FramesAvailable()
|
2019-12-23 07:02:11 +00:00
|
|
|
{
|
|
|
|
// drop any buffer as soon as they're available
|
2020-06-08 16:05:49 +00:00
|
|
|
DropFrames(GetSamplesAvailable());
|
2019-12-23 07:02:11 +00:00
|
|
|
}
|
2019-12-29 14:45:50 +00:00
|
|
|
|
2020-01-11 03:28:40 +00:00
|
|
|
std::unique_ptr<AudioStream> AudioStream::CreateNullAudioStream()
|
2019-12-29 14:45:50 +00:00
|
|
|
{
|
2020-01-11 03:28:40 +00:00
|
|
|
return std::make_unique<NullAudioStream>();
|
2019-12-29 14:45:50 +00:00
|
|
|
}
|