diff options
author | Nicola Mettifogo | 2007-09-19 08:40:12 +0000 |
---|---|---|
committer | Nicola Mettifogo | 2007-09-19 08:40:12 +0000 |
commit | 258901bab96f0050385a9912c8ea0fe2a41b2d6f (patch) | |
tree | a3ae8675b679c9f3b58ac8d97c79369502ea23c1 /sound | |
parent | a89694c0d61a75a960f5bec6c498659c988401cc (diff) | |
download | scummvm-rg350-258901bab96f0050385a9912c8ea0fe2a41b2d6f.tar.gz scummvm-rg350-258901bab96f0050385a9912c8ea0fe2a41b2d6f.tar.bz2 scummvm-rg350-258901bab96f0050385a9912c8ea0fe2a41b2d6f.zip |
Merged common/stdafx.h into common/scummsys.h. All referencing files have been updated.
svn-id: r28966
Diffstat (limited to 'sound')
37 files changed, 27 insertions, 72 deletions
diff --git a/sound/adpcm.cpp b/sound/adpcm.cpp index 616ddd6cf9..ca1eb79c6f 100644 --- a/sound/adpcm.cpp +++ b/sound/adpcm.cpp @@ -23,8 +23,6 @@ * */ -#include "common/stdafx.h" - #include "common/endian.h" #include "sound/adpcm.h" @@ -178,7 +176,7 @@ int ADPCMInputStream::readBufferMSIMA2(int16 *buffer, const int numSamples) { for (samples = 0; samples < numSamples && !_stream->eos() && _stream->pos() < _endpos;) { for (int channel = 0; channel < 2; channel++) { data = _stream->readUint32LE(); - + for (nibble = 0; nibble < 8; nibble++) { byte k = ((data & 0xf0000000) >> 28); buffer[samples + channel + nibble * 2] = TO_LE_16(decodeMSIMA(k)); diff --git a/sound/adpcm.h b/sound/adpcm.h index 8367a6d3f6..772dd63d34 100644 --- a/sound/adpcm.h +++ b/sound/adpcm.h @@ -26,7 +26,6 @@ #ifndef SOUND_ADPCM_H #define SOUND_ADPCM_H -#include "common/stdafx.h" #include "common/scummsys.h" #include "common/stream.h" diff --git a/sound/aiff.cpp b/sound/aiff.cpp index a7489b21ff..884becb212 100644 --- a/sound/aiff.cpp +++ b/sound/aiff.cpp @@ -31,7 +31,6 @@ * (http://sox.sourceforge.net) may be a good place to start from. */ -#include "common/stdafx.h" #include "common/endian.h" #include "common/util.h" #include "common/stream.h" diff --git a/sound/aiff.h b/sound/aiff.h index 852d2074f1..334c19217c 100644 --- a/sound/aiff.h +++ b/sound/aiff.h @@ -26,7 +26,6 @@ #ifndef SOUND_AIFF_H #define SOUND_AIFF_H -#include "common/stdafx.h" #include "common/scummsys.h" namespace Common { class SeekableReadStream; } diff --git a/sound/audiocd.cpp b/sound/audiocd.cpp index a3afcbfffd..343d5bc440 100644 --- a/sound/audiocd.cpp +++ b/sound/audiocd.cpp @@ -23,8 +23,6 @@ * */ -#include "common/stdafx.h" - #include "sound/audiocd.h" #include "sound/audiostream.h" #include "sound/mp3.h" diff --git a/sound/audiocd.h b/sound/audiocd.h index ba3e61289c..83b0374291 100644 --- a/sound/audiocd.h +++ b/sound/audiocd.h @@ -26,7 +26,6 @@ #ifndef SOUND_AUDIOCD_H #define SOUND_AUDIOCD_H -#include "common/stdafx.h" #include "common/scummsys.h" #include "common/singleton.h" #include "sound/mixer.h" diff --git a/sound/audiostream.cpp b/sound/audiostream.cpp index 6a04da5f43..2832b72394 100644 --- a/sound/audiostream.cpp +++ b/sound/audiostream.cpp @@ -23,7 +23,6 @@ * */ -#include "common/stdafx.h" #include "common/endian.h" #include "common/file.h" #include "common/list.h" diff --git a/sound/audiostream.h b/sound/audiostream.h index f3791500f4..05c7257a21 100644 --- a/sound/audiostream.h +++ b/sound/audiostream.h @@ -26,7 +26,6 @@ #ifndef SOUND_AUDIOSTREAM_H #define SOUND_AUDIOSTREAM_H -#include "common/stdafx.h" #include "common/util.h" #include "common/scummsys.h" @@ -87,7 +86,7 @@ public: * In case of an error, the file handle will be closed, but deleting * it is still the responsibilty of the caller. * @param basename a filename without an extension - * @param startTime the (optional) time offset in milliseconds from which to start playback + * @param startTime the (optional) time offset in milliseconds from which to start playback * @param duration the (optional) time in milliseconds specifying how long to play * @param numLoops how often the data shall be looped (0 = infinite) * @return an Audiostream ready to use in case of success; @@ -111,7 +110,7 @@ AudioStream *makeLinearInputStream(const byte *ptr, uint32 len, int rate, byte f */ class AppendableAudioStream : public Audio::AudioStream { public: - + /** * Queue another audio data buffer for playback. The stream * will playback all queued buffers, in the order they were @@ -120,7 +119,7 @@ public: * with new[], not with malloc). */ virtual void queueBuffer(byte *data, uint32 size) = 0; - + /** * Mark the stream as finished, that is, signal that no further data * will be appended to it. Only after this has been done can the diff --git a/sound/flac.h b/sound/flac.h index b95f41d007..5c825847b6 100644 --- a/sound/flac.h +++ b/sound/flac.h @@ -26,7 +26,6 @@ #ifndef SOUND_FLAC_H #define SOUND_FLAC_H -#include "common/stdafx.h" #include "common/scummsys.h" #ifdef USE_FLAC @@ -43,12 +42,12 @@ class AudioStream; /** * Create a new AudioStream from the FLAC data in the given stream. * Allows for looping (which is why we require a SeekableReadStream), - * and specifying only a portion of the data to be played, based + * and specifying only a portion of the data to be played, based * on time offsets. * * @param stream the SeekableReadStream from which to read the FLAC data * @param disposeAfterUse whether to delete the stream after use - * @param startTime the (optional) time offset in milliseconds from which to start playback + * @param startTime the (optional) time offset in milliseconds from which to start playback * @param duration the (optional) time in milliseconds specifying how long to play * @param numLoops how often the data shall be looped (0 = infinite) * @return a new AudioStream, or NULL, if an error occured diff --git a/sound/fmopl.cpp b/sound/fmopl.cpp index 9cf604ba49..15d235c577 100644 --- a/sound/fmopl.cpp +++ b/sound/fmopl.cpp @@ -25,8 +25,6 @@ * Tatsuyuki Satoh. Included from LGPL'ed AdPlug. */ -#include "common/stdafx.h" - #include <stdio.h> #include <stdlib.h> #include <string.h> diff --git a/sound/mididrv.cpp b/sound/mididrv.cpp index 658ebfa457..09a72366f6 100644 --- a/sound/mididrv.cpp +++ b/sound/mididrv.cpp @@ -23,8 +23,6 @@ * */ -#include "common/stdafx.h" - #include "engines/engine.h" #include "common/config-manager.h" #include "common/str.h" @@ -48,7 +46,7 @@ static const MidiDriverDescription s_musicDrivers[] = { {"alsa", "ALSA", MD_ALSA, MDT_MIDI}, #endif -#if defined(UNIX) && !defined(__BEOS__) && !defined(MACOSX) && !defined(__MAEMO__) +#if defined(UNIX) && !defined(__BEOS__) && !defined(MACOSX) && !defined(__MAEMO__) {"seq", "SEQ", MD_SEQ, MDT_MIDI}, #endif @@ -121,7 +119,7 @@ const MidiDriverDescription &MidiDriver::findMusicDriver(const Common::String &s const char *s = str.c_str(); int len = 0; const MidiDriverDescription *md = s_musicDrivers; - + // Scan for string end or a colon while (s[len] != 0 && s[len] != ':') len++; @@ -240,7 +238,7 @@ MidiDriver *MidiDriver::createMidi(int midiDriver) { #endif #endif -#if defined(WIN32) && !defined(_WIN32_WCE) && !defined(__SYMBIAN32__) +#if defined(WIN32) && !defined(_WIN32_WCE) && !defined(__SYMBIAN32__) case MD_WINDOWS: return MidiDriver_WIN_create(); #endif #if defined(__MORPHOS__) diff --git a/sound/midiparser.cpp b/sound/midiparser.cpp index 7d09f4ec0d..b2897dadfa 100644 --- a/sound/midiparser.cpp +++ b/sound/midiparser.cpp @@ -23,7 +23,6 @@ * */ -#include "common/stdafx.h" #include "sound/midiparser.h" #include "sound/mididrv.h" #include "common/util.h" diff --git a/sound/midiparser_smf.cpp b/sound/midiparser_smf.cpp index 45d0e43182..ed5007ecb7 100644 --- a/sound/midiparser_smf.cpp +++ b/sound/midiparser_smf.cpp @@ -23,7 +23,6 @@ * */ -#include "common/stdafx.h" #include "sound/midiparser.h" #include "sound/mididrv.h" #include "common/util.h" @@ -127,7 +126,7 @@ void MidiParser_SMF::parseNextEvent(EventInfo &info) { info.ext.data = _position._play_pos; _position._play_pos += info.length; break; - + default: warning("MidiParser_SMF::parseNextEvent: Unsupported event code %x", info.event); } diff --git a/sound/midiparser_xmidi.cpp b/sound/midiparser_xmidi.cpp index 9e74c48f7e..d2aac49351 100644 --- a/sound/midiparser_xmidi.cpp +++ b/sound/midiparser_xmidi.cpp @@ -23,7 +23,6 @@ * */ -#include "common/stdafx.h" #include "sound/midiparser.h" #include "sound/mididrv.h" #include "common/util.h" @@ -123,7 +122,7 @@ void MidiParser_XMIDI::parseNextEvent(EventInfo &info) { info.ext.data[2] = 0x20; } break; - + default: warning("MidiParser_XMIDI::parseNextEvent: Unsupported event code %x", info.event); } diff --git a/sound/mixer.cpp b/sound/mixer.cpp index 93a661d80f..fc5b21cf32 100644 --- a/sound/mixer.cpp +++ b/sound/mixer.cpp @@ -23,8 +23,6 @@ * */ -#include "common/stdafx.h" - #include "common/file.h" #include "common/util.h" #include "common/system.h" @@ -78,7 +76,7 @@ public: } void pause(bool paused) { //assert((paused && _pauseLevel >= 0) || (!paused && _pauseLevel)); - + if (paused) _pauseLevel++; else if (_pauseLevel > 0) @@ -163,7 +161,7 @@ void Mixer::playRaw( // Create the input stream AudioStream *input = makeLinearInputStream((byte *)sound, size, rate, flags, loopStart, loopEnd); - + // Play it playInputStream(type, handle, input, id, volume, balance, true, false, ((flags & Mixer::FLAG_REVERSE_STEREO) != 0)); } @@ -202,7 +200,7 @@ void Mixer::playInputStream( void Mixer::mix(int16 *buf, uint len) { Common::StackLock lock(_mutex); - + // Since the mixer callback has been called, the mixer must be ready... _mixerReady = true; diff --git a/sound/mixer.h b/sound/mixer.h index 189fcb27f7..d46a933d97 100644 --- a/sound/mixer.h +++ b/sound/mixer.h @@ -26,7 +26,6 @@ #ifndef SOUND_MIXER_H #define SOUND_MIXER_H -#include "common/stdafx.h" #include "common/scummsys.h" #include "common/mutex.h" @@ -204,7 +203,7 @@ public: /** - * Pause/unpause all sounds, including all regular and permanent + * Pause/unpause all sounds, including all regular and permanent * channels * * @param paused true to pause everything, false to unpause @@ -327,7 +326,7 @@ public: * This simply calls the mix() method. */ static void mixCallback(void *s, byte *samples, int len); - + void setReady(bool ready) { _mixerReady = ready; } }; diff --git a/sound/mods/module.cpp b/sound/mods/module.cpp index 96d977d422..90921d24d1 100644 --- a/sound/mods/module.cpp +++ b/sound/mods/module.cpp @@ -23,8 +23,6 @@ * */ -#include "common/stdafx.h" - #include "sound/mods/module.h" #include "common/util.h" @@ -173,7 +171,7 @@ bool Module::load(Common::SeekableReadStream &st, int offs) { if (!sample[i].len) { sample[i].data = 0; } else { - if (offs != 0) { + if (offs != 0) { // For modules that use common samples for (int j = 0; j < NUM_SAMPLES; ++j) { if (!scumm_stricmp((const char *)commonSamples[j].name, (const char *)sample[i].name)) { diff --git a/sound/mods/protracker.cpp b/sound/mods/protracker.cpp index 271e3d8e3e..f40b61ad09 100644 --- a/sound/mods/protracker.cpp +++ b/sound/mods/protracker.cpp @@ -23,8 +23,6 @@ * */ -#include "common/stdafx.h" - #include "sound/mods/protracker.h" #include "sound/mods/paula.h" #include "sound/mods/module.h" diff --git a/sound/mods/protracker.h b/sound/mods/protracker.h index 23e90f0954..ab3e042475 100644 --- a/sound/mods/protracker.h +++ b/sound/mods/protracker.h @@ -26,7 +26,6 @@ #ifndef SOUND_MODS_PROTRACKER_H #define SOUND_MODS_PROTRACKER_H -#include "common/stdafx.h" #include "common/stream.h" namespace Audio { @@ -36,9 +35,9 @@ class AudioStream; /* * Factory function for ProTracker streams. Reads all data from the * given ReadStream and creates an AudioStream from this. No reference - * to the 'stream' object is kept, so you can safely delete it after + * to the 'stream' object is kept, so you can safely delete it after * invoking this factory. - * + * * @param stream the ReadStream from which to read the ProTracker data * @param rate TODO * @param stereo TODO diff --git a/sound/mods/rjp1.cpp b/sound/mods/rjp1.cpp index 3f5582de51..59b8833607 100644 --- a/sound/mods/rjp1.cpp +++ b/sound/mods/rjp1.cpp @@ -23,7 +23,6 @@ * */ -#include "common/stdafx.h" #include "common/endian.h" #include "sound/mods/paula.h" diff --git a/sound/mods/soundfx.cpp b/sound/mods/soundfx.cpp index b68a664a39..057541307a 100644 --- a/sound/mods/soundfx.cpp +++ b/sound/mods/soundfx.cpp @@ -23,7 +23,6 @@ * */ -#include "common/stdafx.h" #include "common/endian.h" #include "sound/mods/paula.h" diff --git a/sound/mp3.h b/sound/mp3.h index ad66666b00..d544e60e0e 100644 --- a/sound/mp3.h +++ b/sound/mp3.h @@ -26,7 +26,6 @@ #ifndef SOUND_MP3_H #define SOUND_MP3_H -#include "common/stdafx.h" #include "common/scummsys.h" #ifdef USE_MAD @@ -43,12 +42,12 @@ class AudioStream; /** * Create a new AudioStream from the MP3 data in the given stream. * Allows for looping (which is why we require a SeekableReadStream), - * and specifying only a portion of the data to be played, based + * and specifying only a portion of the data to be played, based * on time offsets. * * @param stream the SeekableReadStream from which to read the MP3 data * @param disposeAfterUse whether to delete the stream after use - * @param startTime the (optional) time offset in milliseconds from which to start playback + * @param startTime the (optional) time offset in milliseconds from which to start playback * @param duration the (optional) time in milliseconds specifying how long to play * @param numLoops how often the data shall be looped (0 = infinite) * @return a new AudioStream, or NULL, if an error occured diff --git a/sound/mpu401.cpp b/sound/mpu401.cpp index c390e807b2..c2158f1329 100644 --- a/sound/mpu401.cpp +++ b/sound/mpu401.cpp @@ -22,7 +22,6 @@ * $Id$ */ -#include "common/stdafx.h" #include "sound/mpu401.h" #include "common/system.h" #include "common/timer.h" diff --git a/sound/mpu401.h b/sound/mpu401.h index 34bde72a4b..2253ab429c 100644 --- a/sound/mpu401.h +++ b/sound/mpu401.h @@ -26,7 +26,6 @@ #ifndef SOUND_MPU401_H #define SOUND_MPU401_H -#include "common/stdafx.h" #include "sound/mididrv.h" //////////////////////////////////////// diff --git a/sound/null.cpp b/sound/null.cpp index f8da1f2ece..49c57052f9 100644 --- a/sound/null.cpp +++ b/sound/null.cpp @@ -22,7 +22,6 @@ * $Id$ */ -#include "common/stdafx.h" #include "sound/mpu401.h" /* NULL driver */ diff --git a/sound/rate.cpp b/sound/rate.cpp index 6e8e83f9a6..953a305ec2 100644 --- a/sound/rate.cpp +++ b/sound/rate.cpp @@ -31,7 +31,6 @@ * improvments over the original code were made. */ -#include "common/stdafx.h" #include "sound/audiostream.h" #include "sound/rate.h" #include "sound/mixer.h" @@ -141,7 +140,7 @@ int SimpleRateConverter<stereo, reverseStereo>::flow(AudioStream &input, st_samp // output right channel clampedAdd(obuf[reverseStereo ^ 1], (out1 * (int)vol_r) / Audio::Mixer::kMaxMixerVolume); - + obuf += 2; } return ST_SUCCESS; @@ -256,7 +255,7 @@ int LinearRateConverter<stereo, reverseStereo>::flow(AudioStream &input, st_samp // output right channel clampedAdd(obuf[reverseStereo ^ 1], (out1 * (int)vol_r) / Audio::Mixer::kMaxMixerVolume); - + obuf += 2; // Increment output position @@ -314,7 +313,7 @@ public: // output right channel clampedAdd(obuf[reverseStereo ^ 1], (out1 * (int)vol_r) / Audio::Mixer::kMaxMixerVolume); - + obuf += 2; } return ST_SUCCESS; diff --git a/sound/rate_arm.cpp b/sound/rate_arm.cpp index ad8f0519c6..0935b95ebd 100644 --- a/sound/rate_arm.cpp +++ b/sound/rate_arm.cpp @@ -44,7 +44,6 @@ * other improvments over the original code were made. */ -#include "common/stdafx.h" #include "sound/audiostream.h" #include "sound/rate.h" #include "sound/mixer.h" diff --git a/sound/softsynth/emumidi.h b/sound/softsynth/emumidi.h index 3876f69fa0..1e8f4bf2a7 100644 --- a/sound/softsynth/emumidi.h +++ b/sound/softsynth/emumidi.h @@ -22,7 +22,6 @@ * $Id$ */ -#include "common/stdafx.h" #include "sound/audiostream.h" #include "sound/mididrv.h" #include "sound/mixer.h" diff --git a/sound/softsynth/fluidsynth.cpp b/sound/softsynth/fluidsynth.cpp index 486f6aaa08..4a61cd023b 100644 --- a/sound/softsynth/fluidsynth.cpp +++ b/sound/softsynth/fluidsynth.cpp @@ -22,12 +22,10 @@ * $Id$ */ -#include "common/stdafx.h" #include "common/scummsys.h" #ifdef USE_FLUIDSYNTH -#include "common/stdafx.h" #include "common/config-manager.h" #include "sound/mpu401.h" #include "sound/softsynth/emumidi.h" diff --git a/sound/softsynth/mt32.cpp b/sound/softsynth/mt32.cpp index acf2f0805a..706db826af 100644 --- a/sound/softsynth/mt32.cpp +++ b/sound/softsynth/mt32.cpp @@ -22,7 +22,6 @@ * $Id$ */ -#include "common/stdafx.h" #include "common/scummsys.h" #ifdef USE_MT32EMU diff --git a/sound/softsynth/mt32/freeverb.cpp b/sound/softsynth/mt32/freeverb.cpp index a364f4d45c..2a372fe19f 100644 --- a/sound/softsynth/mt32/freeverb.cpp +++ b/sound/softsynth/mt32/freeverb.cpp @@ -29,7 +29,6 @@ // http://www.dreampoint.co.uk // This code is public domain -#include "common/stdafx.h" #include "sound/softsynth/mt32/freeverb.h" comb::comb() { diff --git a/sound/softsynth/ym2612.h b/sound/softsynth/ym2612.h index c3be131a91..5fb2f32ef0 100644 --- a/sound/softsynth/ym2612.h +++ b/sound/softsynth/ym2612.h @@ -25,7 +25,6 @@ #ifndef SOUND_SOFTSYNTH_Y2612_H #define SOUND_SOFTSYNTH_Y2612_H -#include "common/stdafx.h" #include "common/scummsys.h" #include "sound/softsynth/emumidi.h" diff --git a/sound/voc.cpp b/sound/voc.cpp index c4f99bbf93..422cf34457 100644 --- a/sound/voc.cpp +++ b/sound/voc.cpp @@ -23,7 +23,6 @@ * */ -#include "common/stdafx.h" #include "common/endian.h" #include "common/util.h" #include "common/stream.h" @@ -110,7 +109,7 @@ static byte *loadVOCFromStream(Common::ReadStream &stream, int &size, int &rate, break; } packing = stream.readUint16LE(); - stream.readUint32LE(); + stream.readUint32LE(); len -= 12; } debug(9, "VOC Data Block: %d, %d, %d", rate, packing, len); diff --git a/sound/voc.h b/sound/voc.h index fd19a29c5a..4641b3b6aa 100644 --- a/sound/voc.h +++ b/sound/voc.h @@ -26,7 +26,6 @@ #ifndef SOUND_VOC_H #define SOUND_VOC_H -#include "common/stdafx.h" #include "common/scummsys.h" namespace Common { class ReadStream; } diff --git a/sound/vorbis.h b/sound/vorbis.h index 98430e6aaa..758bfd9487 100644 --- a/sound/vorbis.h +++ b/sound/vorbis.h @@ -26,7 +26,6 @@ #ifndef SOUND_VORBIS_H #define SOUND_VORBIS_H -#include "common/stdafx.h" #include "common/scummsys.h" #ifdef USE_VORBIS @@ -43,12 +42,12 @@ class AudioStream; /** * Create a new AudioStream from the Ogg Vorbis data in the given stream. * Allows for looping (which is why we require a SeekableReadStream), - * and specifying only a portion of the data to be played, based + * and specifying only a portion of the data to be played, based * on time offsets. * * @param stream the SeekableReadStream from which to read the Ogg Vorbis data * @param disposeAfterUse whether to delete the stream after use - * @param startTime the (optional) time offset in milliseconds from which to start playback + * @param startTime the (optional) time offset in milliseconds from which to start playback * @param duration the (optional) time in milliseconds specifying how long to play * @param numLoops how often the data shall be looped (0 = infinite) * @return a new AudioStream, or NULL, if an error occured diff --git a/sound/wave.cpp b/sound/wave.cpp index a55514fc71..6c74db2ab3 100644 --- a/sound/wave.cpp +++ b/sound/wave.cpp @@ -23,7 +23,6 @@ * */ -#include "common/stdafx.h" #include "common/util.h" #include "common/stream.h" diff --git a/sound/wave.h b/sound/wave.h index 0d9d89ff76..5387865bcf 100644 --- a/sound/wave.h +++ b/sound/wave.h @@ -26,7 +26,6 @@ #ifndef SOUND_WAVE_H #define SOUND_WAVE_H -#include "common/stdafx.h" #include "common/scummsys.h" namespace Common { class SeekableReadStream; } |