Fixed Null sound

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2783 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
nakeee
2009-03-28 23:04:57 +00:00
parent ec8548dc00
commit 5d9871e85e
5 changed files with 17 additions and 11 deletions

View File

@ -19,11 +19,24 @@
#define _NULLSOUNDSTREAM_H_
#include "SoundStream.h"
#include "Mixer.h"
class NullMixer : public CMixer {
public:
virtual void Mix(short *sample, int numSamples) {}
virtual void PushSamples(short* samples, int num_stereo_samples,
int core_sample_rate) {}
};
class NullSound : public SoundStream
{
public:
NullSound(CMixer *mixer) : SoundStream(mixer) {}
NullSound(CMixer *mixer) : SoundStream(mixer)
{
delete m_mixer;
m_mixer = new NullMixer();
}
virtual ~NullSound() {}