diff options
author | Max Horn | 2004-01-03 01:28:00 +0000 |
---|---|---|
committer | Max Horn | 2004-01-03 01:28:00 +0000 |
commit | b1d729d6dd23c093b18d9093a195a399d44d69ce (patch) | |
tree | f6d1ea139254ceb2998d17e3d500988d495afebb | |
parent | 81481ad6da949340fc0e886b08d404b7cd3d7b77 (diff) | |
download | scummvm-rg350-b1d729d6dd23c093b18d9093a195a399d44d69ce.tar.gz scummvm-rg350-b1d729d6dd23c093b18d9093a195a399d44d69ce.tar.bz2 scummvm-rg350-b1d729d6dd23c093b18d9093a195a399d44d69ce.zip |
renamed SimonSound class back to just Sound (now that we use namespaces that is just fine)
svn-id: r12098
-rw-r--r-- | simon/simon.cpp | 2 | ||||
-rw-r--r-- | simon/simon.h | 2 | ||||
-rw-r--r-- | simon/sound.cpp | 26 | ||||
-rw-r--r-- | simon/sound.h | 6 |
4 files changed, 18 insertions, 18 deletions
diff --git a/simon/simon.cpp b/simon/simon.cpp index 25c75b4e82..7bdddc8066 100644 --- a/simon/simon.cpp +++ b/simon/simon.cpp @@ -4796,7 +4796,7 @@ void SimonEngine::go() { setup_vga_file_buf_pointers(); - _sound = new SimonSound(_game, gss, _gameDataPath, _mixer); + _sound = new Sound(_game, gss, _gameDataPath, _mixer); if (ConfMan.hasKey("sfx_mute") && ConfMan.getBool("sfx_mute") == 1) { if (_game == GAME_SIMON1DOS) diff --git a/simon/simon.h b/simon/simon.h index 28814501d8..3286e1bda7 100644 --- a/simon/simon.h +++ b/simon/simon.h @@ -338,7 +338,7 @@ protected: int _num_screen_updates; int _vga_tick_counter; - SimonSound *_sound; + Sound *_sound; bool _effects_paused; bool _ambient_paused; diff --git a/simon/sound.cpp b/simon/sound.cpp index 9bbee43149..33759e14af 100644 --- a/simon/sound.cpp +++ b/simon/sound.cpp @@ -229,7 +229,7 @@ void VorbisSound::playSound(uint sound, PlayingSoundHandle *handle, byte flags) } #endif -SimonSound::SimonSound(const byte game, const GameSpecificSettings *gss, const Common::String &gameDataPath, SoundMixer *mixer) +Sound::Sound(const byte game, const GameSpecificSettings *gss, const Common::String &gameDataPath, SoundMixer *mixer) : _game(game), _gameDataPath(gameDataPath), _mixer(mixer) { _voice = 0; _effects = 0; @@ -341,7 +341,7 @@ SimonSound::SimonSound(const byte game, const GameSpecificSettings *gss, const C } } -SimonSound::~SimonSound() { +Sound::~Sound() { delete _voice; delete _effects; @@ -349,7 +349,7 @@ SimonSound::~SimonSound() { free(_offsets); } -void SimonSound::readSfxFile(const char *filename, const Common::String &gameDataPath) { +void Sound::readSfxFile(const char *filename, const Common::String &gameDataPath) { stopAll(); File *file = new File(); @@ -376,7 +376,7 @@ void SimonSound::readSfxFile(const char *filename, const Common::String &gameDat _effects = new WavSound(_mixer, file); } -void SimonSound::loadSfxTable(File *gameFile, uint32 base) { +void Sound::loadSfxTable(File *gameFile, uint32 base) { stopAll(); if (_game & GF_WIN) @@ -385,7 +385,7 @@ void SimonSound::loadSfxTable(File *gameFile, uint32 base) { _effects = new VocSound(_mixer, gameFile, base); } -void SimonSound::readVoiceFile(const char *filename, const Common::String &gameDataPath) { +void Sound::readVoiceFile(const char *filename, const Common::String &gameDataPath) { stopAll(); File *file = new File(); @@ -408,7 +408,7 @@ void SimonSound::readVoiceFile(const char *filename, const Common::String &gameD _voice = new RawSound(_mixer, file, 0, SOUND_BIG_ENDIAN); } -void SimonSound::playVoice(uint sound) { +void Sound::playVoice(uint sound) { if (_game == GAME_SIMON2MAC && _filenums) { if (_last_voice_file != _filenums[sound]) { stopAll(); @@ -437,7 +437,7 @@ void SimonSound::playVoice(uint sound) { _voice->playSound(sound, &_voice_handle, (_game == GAME_SIMON1CD32) ? 0 : SoundMixer::FLAG_UNSIGNED); } -void SimonSound::playEffects(uint sound) { +void Sound::playEffects(uint sound) { if (!_effects) return; @@ -447,7 +447,7 @@ void SimonSound::playEffects(uint sound) { _effects->playSound(sound, &_effects_handle, (_game == GAME_SIMON1CD32) ? 0 : SoundMixer::FLAG_UNSIGNED); } -void SimonSound::playAmbient(uint sound) { +void Sound::playAmbient(uint sound) { if (!_effects) return; @@ -463,24 +463,24 @@ void SimonSound::playAmbient(uint sound) { _effects->playSound(sound, &_ambient_handle, SoundMixer::FLAG_LOOP|SoundMixer::FLAG_UNSIGNED); } -bool SimonSound::hasVoice() { +bool Sound::hasVoice() { return _voice_file; } -void SimonSound::stopVoice() { +void Sound::stopVoice() { _mixer->stopHandle(_voice_handle); } -void SimonSound::stopAll() { +void Sound::stopAll() { _mixer->stopAll(); _ambient_playing = 0; } -void SimonSound::effectsPause(bool b) { +void Sound::effectsPause(bool b) { _effects_paused = b; } -void SimonSound::ambientPause(bool b) { +void Sound::ambientPause(bool b) { _ambient_paused = b; if (_ambient_paused && _ambient_playing) { diff --git a/simon/sound.h b/simon/sound.h index c38a669392..da336f78d2 100644 --- a/simon/sound.h +++ b/simon/sound.h @@ -28,7 +28,7 @@ namespace Simon { class BaseSound; -class SimonSound { +class Sound { private: byte _game; const Common::String _gameDataPath; @@ -53,8 +53,8 @@ public: bool _voice_file; uint _ambient_playing; - SimonSound(const byte game, const GameSpecificSettings *gss, const Common::String &gameDataPath, SoundMixer *mixer); - ~SimonSound(); + Sound(const byte game, const GameSpecificSettings *gss, const Common::String &gameDataPath, SoundMixer *mixer); + ~Sound(); void readSfxFile(const char *filename, const Common::String &gameDataPath); void loadSfxTable(File *gameFile, uint32 base); |