diff options
-rw-r--r-- | audio/mixer.cpp | 4 | ||||
-rw-r--r-- | audio/mixer_intern.h | 2 | ||||
-rw-r--r-- | backends/mixer/nullmixer/nullsdl-mixer.cpp | 2 | ||||
-rw-r--r-- | backends/mixer/sdl/sdl-mixer.cpp | 6 | ||||
-rw-r--r-- | backends/platform/3ds/osystem-audio.cpp | 2 | ||||
-rw-r--r-- | backends/platform/android/android.cpp | 2 | ||||
-rw-r--r-- | backends/platform/dc/dcmain.cpp | 2 | ||||
-rw-r--r-- | backends/platform/ds/arm9/source/osystem_ds.cpp | 2 | ||||
-rw-r--r-- | backends/platform/ios7/ios7_osys_sound.cpp | 2 | ||||
-rw-r--r-- | backends/platform/iphone/osys_sound.cpp | 2 | ||||
-rw-r--r-- | backends/platform/n64/osys_n64_base.cpp | 2 | ||||
-rw-r--r-- | backends/platform/null/null.cpp | 2 | ||||
-rw-r--r-- | backends/platform/ps2/systemps2.cpp | 2 | ||||
-rw-r--r-- | backends/platform/psp/osys_psp.cpp | 2 | ||||
-rw-r--r-- | backends/platform/tizen/audio.cpp | 4 | ||||
-rw-r--r-- | backends/platform/tizen/audio.h | 2 | ||||
-rw-r--r-- | backends/platform/tizen/system.cpp | 2 | ||||
-rw-r--r-- | backends/platform/wii/osystem_sfx.cpp | 2 |
18 files changed, 21 insertions, 23 deletions
diff --git a/audio/mixer.cpp b/audio/mixer.cpp index 274f8e9de6..9eb3e6714a 100644 --- a/audio/mixer.cpp +++ b/audio/mixer.cpp @@ -23,7 +23,6 @@ #include "gui/EventRecorder.h" #include "common/util.h" -#include "common/system.h" #include "common/textconsole.h" #include "audio/mixer_intern.h" @@ -173,8 +172,7 @@ private: #pragma mark --- Mixer --- #pragma mark - -// TODO: parameter "system" is unused -MixerImpl::MixerImpl(OSystem *system, uint sampleRate) +MixerImpl::MixerImpl(uint sampleRate) : _mutex(), _sampleRate(sampleRate), _mixerReady(false), _handleSeed(0), _soundTypeSettings() { assert(sampleRate > 0); diff --git a/audio/mixer_intern.h b/audio/mixer_intern.h index a8b7981571..9cb7fa0e9e 100644 --- a/audio/mixer_intern.h +++ b/audio/mixer_intern.h @@ -73,7 +73,7 @@ private: public: - MixerImpl(OSystem *system, uint sampleRate); + MixerImpl(uint sampleRate); ~MixerImpl(); virtual bool isReady() const { return _mixerReady; } diff --git a/backends/mixer/nullmixer/nullsdl-mixer.cpp b/backends/mixer/nullmixer/nullsdl-mixer.cpp index 97b59bb2ed..8f112e1fa0 100644 --- a/backends/mixer/nullmixer/nullsdl-mixer.cpp +++ b/backends/mixer/nullmixer/nullsdl-mixer.cpp @@ -38,7 +38,7 @@ NullSdlMixerManager::~NullSdlMixerManager() { } void NullSdlMixerManager::init() { - _mixer = new Audio::MixerImpl(g_system, _outputRate); + _mixer = new Audio::MixerImpl(_outputRate); assert(_mixer); _mixer->setReady(true); } diff --git a/backends/mixer/sdl/sdl-mixer.cpp b/backends/mixer/sdl/sdl-mixer.cpp index 0af0748a2a..2a46d877b2 100644 --- a/backends/mixer/sdl/sdl-mixer.cpp +++ b/backends/mixer/sdl/sdl-mixer.cpp @@ -81,7 +81,7 @@ void SdlMixerManager::init() { warning("Could not open audio device: %s", SDL_GetError()); // The mixer is not marked as ready - _mixer = new Audio::MixerImpl(g_system, desired.freq); + _mixer = new Audio::MixerImpl(desired.freq); return; } @@ -96,7 +96,7 @@ void SdlMixerManager::init() { warning("Could not open audio device: %s", SDL_GetError()); // The mixer is not marked as ready - _mixer = new Audio::MixerImpl(g_system, desired.freq); + _mixer = new Audio::MixerImpl(desired.freq); return; } @@ -118,7 +118,7 @@ void SdlMixerManager::init() { error("SDL mixer output requires stereo output device"); #endif - _mixer = new Audio::MixerImpl(g_system, _obtained.freq); + _mixer = new Audio::MixerImpl(_obtained.freq); assert(_mixer); _mixer->setReady(true); diff --git a/backends/platform/3ds/osystem-audio.cpp b/backends/platform/3ds/osystem-audio.cpp index 043aaf1fe2..3434b53fd3 100644 --- a/backends/platform/3ds/osystem-audio.cpp +++ b/backends/platform/3ds/osystem-audio.cpp @@ -75,7 +75,7 @@ static void audioThreadFunc(void *arg) { } void OSystem_3DS::initAudio() { - _mixer = new Audio::MixerImpl(this, 22050); + _mixer = new Audio::MixerImpl(22050); hasAudio = R_SUCCEEDED(ndspInit()); _mixer->setReady(false); diff --git a/backends/platform/android/android.cpp b/backends/platform/android/android.cpp index e450c70e3a..78657d342f 100644 --- a/backends/platform/android/android.cpp +++ b/backends/platform/android/android.cpp @@ -347,7 +347,7 @@ void OSystem_Android::initBackend() { gettimeofday(&_startTime, 0); - _mixer = new Audio::MixerImpl(this, _audio_sample_rate); + _mixer = new Audio::MixerImpl(_audio_sample_rate); _mixer->setReady(true); _timer_thread_exit = false; diff --git a/backends/platform/dc/dcmain.cpp b/backends/platform/dc/dcmain.cpp index 31fd883cd6..c74646c729 100644 --- a/backends/platform/dc/dcmain.cpp +++ b/backends/platform/dc/dcmain.cpp @@ -58,7 +58,7 @@ void OSystem_Dreamcast::initBackend() _timerManager = new DefaultTimerManager(); uint sampleRate = initSound(); - _mixer = new Audio::MixerImpl(this, sampleRate); + _mixer = new Audio::MixerImpl(sampleRate); _mixer->setReady(true); _audiocdManager = new DCCDManager(); diff --git a/backends/platform/ds/arm9/source/osystem_ds.cpp b/backends/platform/ds/arm9/source/osystem_ds.cpp index c9a1f08758..a387f0a694 100644 --- a/backends/platform/ds/arm9/source/osystem_ds.cpp +++ b/backends/platform/ds/arm9/source/osystem_ds.cpp @@ -130,7 +130,7 @@ void OSystem_DS::initBackend() { DS::startSound(11025, 4096); } - _mixer = new Audio::MixerImpl(this, DS::getSoundFrequency()); + _mixer = new Audio::MixerImpl(DS::getSoundFrequency()); _mixer->setReady(true); /* TODO/FIXME: The NDS should use a custom AudioCD manager instance! diff --git a/backends/platform/ios7/ios7_osys_sound.cpp b/backends/platform/ios7/ios7_osys_sound.cpp index 07e9458711..fdbb1f2ecb 100644 --- a/backends/platform/ios7/ios7_osys_sound.cpp +++ b/backends/platform/ios7/ios7_osys_sound.cpp @@ -46,7 +46,7 @@ void OSystem_iOS7::mixCallback(void *sys, byte *samples, int len) { } void OSystem_iOS7::setupMixer() { - _mixer = new Audio::MixerImpl(this, AUDIO_SAMPLE_RATE); + _mixer = new Audio::MixerImpl(AUDIO_SAMPLE_RATE); s_soundCallback = mixCallback; s_soundParam = this; diff --git a/backends/platform/iphone/osys_sound.cpp b/backends/platform/iphone/osys_sound.cpp index 34c1cbff34..533487503e 100644 --- a/backends/platform/iphone/osys_sound.cpp +++ b/backends/platform/iphone/osys_sound.cpp @@ -46,7 +46,7 @@ void OSystem_IPHONE::mixCallback(void *sys, byte *samples, int len) { } void OSystem_IPHONE::setupMixer() { - _mixer = new Audio::MixerImpl(this, AUDIO_SAMPLE_RATE); + _mixer = new Audio::MixerImpl(AUDIO_SAMPLE_RATE); s_soundCallback = mixCallback; s_soundParam = this; diff --git a/backends/platform/n64/osys_n64_base.cpp b/backends/platform/n64/osys_n64_base.cpp index 357bdf2584..277cc1ff18 100644 --- a/backends/platform/n64/osys_n64_base.cpp +++ b/backends/platform/n64/osys_n64_base.cpp @@ -881,7 +881,7 @@ void OSystem_N64::setTimerCallback(TimerProc callback, int interval) { } void OSystem_N64::setupMixer(void) { - _mixer = new Audio::MixerImpl(this, DEFAULT_SOUND_SAMPLE_RATE); + _mixer = new Audio::MixerImpl(DEFAULT_SOUND_SAMPLE_RATE); _mixer->setReady(false); enableAudioPlayback(); diff --git a/backends/platform/null/null.cpp b/backends/platform/null/null.cpp index 2f34ae8f93..6261212f5f 100644 --- a/backends/platform/null/null.cpp +++ b/backends/platform/null/null.cpp @@ -93,7 +93,7 @@ void OSystem_NULL::initBackend() { _eventManager = new DefaultEventManager(this); _savefileManager = new DefaultSaveFileManager(); _graphicsManager = new NullGraphicsManager(); - _mixer = new Audio::MixerImpl(this, 22050); + _mixer = new Audio::MixerImpl(22050); ((Audio::MixerImpl *)_mixer)->setReady(false); diff --git a/backends/platform/ps2/systemps2.cpp b/backends/platform/ps2/systemps2.cpp index 2a8f2d65d0..a9fc71c90a 100644 --- a/backends/platform/ps2/systemps2.cpp +++ b/backends/platform/ps2/systemps2.cpp @@ -378,7 +378,7 @@ OSystem_PS2::OSystem_PS2(const char *elfPath) { void OSystem_PS2::init(void) { sioprintf("Timer...\n"); _timerManager = new DefaultTimerManager(); - _scummMixer = new Audio::MixerImpl(this, 48000); + _scummMixer = new Audio::MixerImpl(48000); _scummMixer->setReady(true); initTimer(); diff --git a/backends/platform/psp/osys_psp.cpp b/backends/platform/psp/osys_psp.cpp index a65840669b..2febf91b04 100644 --- a/backends/platform/psp/osys_psp.cpp +++ b/backends/platform/psp/osys_psp.cpp @@ -412,7 +412,7 @@ void OSystem_PSP::setupMixer(void) { return; } samplesPerSec = _audio.getFrequency(); // may have been changed by audio system - _mixer = new Audio::MixerImpl(this, samplesPerSec); + _mixer = new Audio::MixerImpl(samplesPerSec); assert(_mixer); _mixer->setReady(true); _audio.unpause(); diff --git a/backends/platform/tizen/audio.cpp b/backends/platform/tizen/audio.cpp index b2e061baef..bedac2de61 100644 --- a/backends/platform/tizen/audio.cpp +++ b/backends/platform/tizen/audio.cpp @@ -43,7 +43,7 @@ AudioThread::AudioThread() : _muted(true) { } -Audio::MixerImpl *AudioThread::Construct(OSystem *system) { +Audio::MixerImpl *AudioThread::Construct() { logEntered(); if (IsFailed(EventDrivenThread::Construct(DEFAULT_STACK_SIZE, THREAD_PRIORITY_HIGH))) { @@ -51,7 +51,7 @@ Audio::MixerImpl *AudioThread::Construct(OSystem *system) { return NULL; } - _mixer = new Audio::MixerImpl(system, 44100); + _mixer = new Audio::MixerImpl(44100); return _mixer; } diff --git a/backends/platform/tizen/audio.h b/backends/platform/tizen/audio.h index de4724eb3c..db87d78123 100644 --- a/backends/platform/tizen/audio.h +++ b/backends/platform/tizen/audio.h @@ -50,7 +50,7 @@ public: AudioThread(void); ~AudioThread(void); - Audio::MixerImpl *Construct(OSystem *system); + Audio::MixerImpl *Construct(); bool isSilentMode(); void setMute(bool on); diff --git a/backends/platform/tizen/system.cpp b/backends/platform/tizen/system.cpp index 3eaa99e39b..23b07187bb 100644 --- a/backends/platform/tizen/system.cpp +++ b/backends/platform/tizen/system.cpp @@ -287,7 +287,7 @@ result TizenSystem::initModules() { return E_OUT_OF_MEMORY; } - _mixer = _audioThread->Construct(this); + _mixer = _audioThread->Construct(); if (!_mixer) { return E_OUT_OF_MEMORY; } diff --git a/backends/platform/wii/osystem_sfx.cpp b/backends/platform/wii/osystem_sfx.cpp index 445bb2ef52..ea7dc9e398 100644 --- a/backends/platform/wii/osystem_sfx.cpp +++ b/backends/platform/wii/osystem_sfx.cpp @@ -71,7 +71,7 @@ static void * sfx_thread_func(void *arg) { } void OSystem_Wii::initSfx() { - _mixer = new Audio::MixerImpl(this, 48000); + _mixer = new Audio::MixerImpl(48000); sfx_thread_running = false; sfx_thread_quit = false; |