aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorMax Horn2015-07-19 17:06:18 +0200
committerMax Horn2015-07-19 17:06:18 +0200
commit91e925d8cec1eff97d76ba4f0870171a3cb5b3b3 (patch)
tree2cdad056dbd9bbd1327155d6b34f804739f9fbdb /engines
parentb52d48e0da709e6b78bf08a3cf4b2df3e100b500 (diff)
downloadscummvm-rg350-91e925d8cec1eff97d76ba4f0870171a3cb5b3b3.tar.gz
scummvm-rg350-91e925d8cec1eff97d76ba4f0870171a3cb5b3b3.tar.bz2
scummvm-rg350-91e925d8cec1eff97d76ba4f0870171a3cb5b3b3.zip
GOB: Get rid of unused Audio::mixer references
Also remove the unused AdLib::_rate member variable.
Diffstat (limited to 'engines')
-rw-r--r--engines/gob/sound/adlib.cpp2
-rw-r--r--engines/gob/sound/adlib.h5
-rw-r--r--engines/gob/sound/adlplayer.cpp2
-rw-r--r--engines/gob/sound/adlplayer.h2
-rw-r--r--engines/gob/sound/musplayer.cpp2
-rw-r--r--engines/gob/sound/musplayer.h2
-rw-r--r--engines/gob/sound/sound.cpp8
7 files changed, 10 insertions, 13 deletions
diff --git a/engines/gob/sound/adlib.cpp b/engines/gob/sound/adlib.cpp
index 995cc48824..1e024d5a50 100644
--- a/engines/gob/sound/adlib.cpp
+++ b/engines/gob/sound/adlib.cpp
@@ -115,7 +115,7 @@ const uint16 AdLib::kHihatParams [kParamCount] = {
0, 1, 0, 15, 11, 0, 7, 5, 0, 0, 0, 0, 0, 0 };
-AdLib::AdLib(Audio::Mixer &mixer, int callbackFreq) : _mixer(&mixer), _opl(0),
+AdLib::AdLib(int callbackFreq) : _opl(0),
_toPoll(0), _repCount(0), _first(true), _playing(false), _ended(true), _volume(0) {
initFreqs();
diff --git a/engines/gob/sound/adlib.h b/engines/gob/sound/adlib.h
index 28ebf9d998..d60458295c 100644
--- a/engines/gob/sound/adlib.h
+++ b/engines/gob/sound/adlib.h
@@ -37,7 +37,7 @@ namespace Gob {
/** Base class for a player of an AdLib music format. */
class AdLib {
public:
- AdLib(Audio::Mixer &mixer, int callbackFrequency);
+ AdLib(int callbackFrequency);
virtual ~AdLib();
bool isPlaying() const; ///< Are we currently playing?
@@ -225,15 +225,12 @@ private:
static const uint16 kHihatParams [kParamCount];
- Audio::Mixer *_mixer;
OPL::OPL *_opl;
Common::Mutex _mutex;
int _volume;
- uint32 _rate;
-
uint32 _toPoll;
int32 _repCount;
diff --git a/engines/gob/sound/adlplayer.cpp b/engines/gob/sound/adlplayer.cpp
index e5a276032b..6354d8c37f 100644
--- a/engines/gob/sound/adlplayer.cpp
+++ b/engines/gob/sound/adlplayer.cpp
@@ -28,7 +28,7 @@
namespace Gob {
-ADLPlayer::ADLPlayer(Audio::Mixer &mixer) : AdLib(mixer, 1000),
+ADLPlayer::ADLPlayer() : AdLib(1000),
_songData(0), _songDataSize(0), _playPos(0) {
}
diff --git a/engines/gob/sound/adlplayer.h b/engines/gob/sound/adlplayer.h
index bd43cc091c..50e1db5b70 100644
--- a/engines/gob/sound/adlplayer.h
+++ b/engines/gob/sound/adlplayer.h
@@ -36,7 +36,7 @@ namespace Gob {
/** A player for Coktel Vision's ADL music format. */
class ADLPlayer : public AdLib {
public:
- ADLPlayer(Audio::Mixer &mixer);
+ ADLPlayer();
~ADLPlayer();
bool load(Common::SeekableReadStream &adl);
diff --git a/engines/gob/sound/musplayer.cpp b/engines/gob/sound/musplayer.cpp
index 2c0330e70a..dcbb712b56 100644
--- a/engines/gob/sound/musplayer.cpp
+++ b/engines/gob/sound/musplayer.cpp
@@ -27,7 +27,7 @@
namespace Gob {
-MUSPlayer::MUSPlayer(Audio::Mixer &mixer) : AdLib(mixer, 60),
+MUSPlayer::MUSPlayer() : AdLib(60),
_songData(0), _songDataSize(0), _playPos(0), _songID(0) {
}
diff --git a/engines/gob/sound/musplayer.h b/engines/gob/sound/musplayer.h
index 7c1189b84b..973192ffd9 100644
--- a/engines/gob/sound/musplayer.h
+++ b/engines/gob/sound/musplayer.h
@@ -40,7 +40,7 @@ namespace Gob {
*/
class MUSPlayer : public AdLib {
public:
- MUSPlayer(Audio::Mixer &mixer);
+ MUSPlayer();
~MUSPlayer();
/** Load the instruments (.SND or .TBR) */
diff --git a/engines/gob/sound/sound.cpp b/engines/gob/sound/sound.cpp
index 9b19b9c52c..22dfe9d3c3 100644
--- a/engines/gob/sound/sound.cpp
+++ b/engines/gob/sound/sound.cpp
@@ -234,7 +234,7 @@ bool Sound::adlibLoadADL(const char *fileName) {
return false;
if (!_adlPlayer)
- _adlPlayer = new ADLPlayer(*_vm->_mixer);
+ _adlPlayer = new ADLPlayer();
debugC(1, kDebugSound, "AdLib: Loading ADL data (\"%s\")", fileName);
@@ -256,7 +256,7 @@ bool Sound::adlibLoadADL(byte *data, uint32 size, int index) {
return false;
if (!_adlPlayer)
- _adlPlayer = new ADLPlayer(*_vm->_mixer);
+ _adlPlayer = new ADLPlayer();
debugC(1, kDebugSound, "AdLib: Loading ADL data (%d)", index);
@@ -749,7 +749,7 @@ void Sound::createMDYPlayer() {
delete _adlPlayer;
_adlPlayer = 0;
- _mdyPlayer = new MUSPlayer(*_vm->_mixer);
+ _mdyPlayer = new MUSPlayer();
}
void Sound::createADLPlayer() {
@@ -759,7 +759,7 @@ void Sound::createADLPlayer() {
delete _mdyPlayer;
_mdyPlayer= 0;
- _adlPlayer = new ADLPlayer(*_vm->_mixer);
+ _adlPlayer = new ADLPlayer();
}
} // End of namespace Gob