Files
dolphin/Source/Core/AudioCommon/NullSoundStream.h
T

28 lines
604 B
C++
Raw Normal View History

// Copyright 2008 Dolphin Emulator Project
2015-05-18 01:08:10 +02:00
// Licensed under GPLv2+
// Refer to the license.txt file included.
2010-11-14 23:56:26 +00:00
#pragma once
2010-11-14 23:56:26 +00:00
2015-12-05 14:33:33 -05:00
#include <array>
2014-02-17 05:18:15 -05:00
#include "AudioCommon/SoundStream.h"
2010-11-14 23:56:26 +00:00
2014-03-18 10:37:45 -04:00
class NullSound final : public SoundStream
2010-11-14 23:56:26 +00:00
{
public:
bool Start() override;
void SoundLoop() override;
void SetVolume(int volume) override;
void Stop() override;
void Clear(bool mute) override;
void Update() override;
static bool isValid() { return true; }
private:
static constexpr size_t BUFFER_SIZE = 48000 * 4 / 32;
// Playback position
2015-12-05 14:33:33 -05:00
std::array<short, BUFFER_SIZE / sizeof(short)> m_realtime_buffer;
2010-11-14 23:56:26 +00:00
};