aboutsummaryrefslogtreecommitdiff
path: root/engines/agi/sound.cpp
diff options
context:
space:
mode:
authorKari Salminen2007-08-15 16:40:45 +0000
committerKari Salminen2007-08-15 16:40:45 +0000
commitfe9bb43622617def372a985c0f639ef1a90bd5d6 (patch)
tree6750edb045ccefc20afdd751f170047d74299874 /engines/agi/sound.cpp
parentd4998087aa625d50e65d0ab2e6b96b52d9926590 (diff)
downloadscummvm-rg350-fe9bb43622617def372a985c0f639ef1a90bd5d6.tar.gz
scummvm-rg350-fe9bb43622617def372a985c0f639ef1a90bd5d6.tar.bz2
scummvm-rg350-fe9bb43622617def372a985c0f639ef1a90bd5d6.zip
Removed use of USE_IIGS_SOUND (#define).
svn-id: r28626
Diffstat (limited to 'engines/agi/sound.cpp')
-rw-r--r--engines/agi/sound.cpp20
1 files changed, 0 insertions, 20 deletions
diff --git a/engines/agi/sound.cpp b/engines/agi/sound.cpp
index 2ce4f3fb06..fb0f6f592f 100644
--- a/engines/agi/sound.cpp
+++ b/engines/agi/sound.cpp
@@ -42,8 +42,6 @@ static bool g_useChorus = true;
/* TODO: add support for variable sampling rate in the output device
*/
-#ifdef USE_IIGS_SOUND
-
/** Reads an Apple IIGS envelope from then given stream. */
bool IIgsEnvelope::read(Common::SeekableReadStream &stream) {
for (int segNum = 0; segNum < ENVELOPE_SEGMENT_COUNT; segNum++) {
@@ -247,8 +245,6 @@ Audio::AudioStream *SoundMgr::makeIIgsSampleStream(Common::SeekableReadStream &s
return result;
}
-#endif
-
static int playing;
static ChannelInfo chn[NUM_CHANNELS];
static int endflag = -1;
@@ -293,8 +289,6 @@ static int16 waveformMac[WAVEFORM_SIZE] = {
-175, -172, -165, -159, -137, -114, -67, -19
};
-#ifdef USE_IIGS_SOUND
-
static uint16 period[] = {
1024, 1085, 1149, 1218, 1290, 1367,
1448, 1534, 1625, 1722, 1825, 1933
@@ -313,8 +307,6 @@ static int noteToPeriod(int note) {
return 10 * (period[note % 12] >> (note / 12 - 3));
}
-#endif /* USE_IIGS_SOUND */
-
void SoundMgr::unloadSound(int resnum) {
if (_vm->_game.dirSound[resnum].flags & RES_LOADED) {
if (_vm->_game.sounds[resnum].isPlaying()) {
@@ -481,9 +473,7 @@ int SoundMgr::initSound() {
report("disabled\n");
}
-#ifdef USE_IIGS_SOUND
loadInstruments();
-#endif
_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_soundHandle, this, -1, Audio::Mixer::kMaxChannelVolume, 0, false, true);
@@ -532,8 +522,6 @@ void SoundMgr::playNote(int i, int freq, int vol) {
}
}
-#ifdef USE_IIGS_SOUND
-
void SoundMgr::playMidiSound() {
uint8 *p;
uint8 parm1, parm2;
@@ -600,8 +588,6 @@ void SoundMgr::playSampleSound() {
playing = 1;
}
-#endif /* USE_IIGS_SOUND */
-
void SoundMgr::playAgiSound() {
int i;
AgiNote note;
@@ -647,14 +633,12 @@ void SoundMgr::playSound() {
if (endflag == -1)
return;
-#ifdef USE_IIGS_SOUND
if (chn[0].type == AGI_SOUND_MIDI) {
/* play_midi_sound (); */
playing = 0;
} else if (chn[0].type == AGI_SOUND_SAMPLE) {
playSampleSound();
} else
-#endif
playAgiSound();
if (!playing) {
@@ -745,8 +729,6 @@ uint32 SoundMgr::mixSound(void) {
return BUFFER_SIZE;
}
-#ifdef USE_IIGS_SOUND
-
#if 0
void Sound::unloadInstruments() {
free(instruments);
@@ -938,8 +920,6 @@ bool SoundMgr::loadInstruments() {
return result;
}
-#endif /* USE_IIGS_SOUND */
-
static void fillAudio(void *udata, int16 *stream, uint len) {
SoundMgr *soundMgr = (SoundMgr *)udata;
uint32 p = 0;