diff options
| author | Eugene Sandulenko | 2010-10-02 09:08:05 +0000 | 
|---|---|---|
| committer | Eugene Sandulenko | 2010-10-02 09:08:05 +0000 | 
| commit | 8dca57e4e9fe6e3d5acf03f96c2b4b4469a888a0 (patch) | |
| tree | 7a544d9ee2317b0ecbc3bbede9552a1d19c507e8 | |
| parent | b695f68eeee249340b7bcd559265c652c54b593a (diff) | |
| download | scummvm-rg350-8dca57e4e9fe6e3d5acf03f96c2b4b4469a888a0.tar.gz scummvm-rg350-8dca57e4e9fe6e3d5acf03f96c2b4b4469a888a0.tar.bz2 scummvm-rg350-8dca57e4e9fe6e3d5acf03f96c2b4b4469a888a0.zip | |
SAGA: Fix bug #3065113 with patched sound glitch
Bug #3065113: "ITE demo: patched sound at intro is not played correctly"
svn-id: r52975
| -rw-r--r-- | engines/saga/sndres.cpp | 4 | 
1 files changed, 2 insertions, 2 deletions
| diff --git a/engines/saga/sndres.cpp b/engines/saga/sndres.cpp index a163fdfa2b..9322918db5 100644 --- a/engines/saga/sndres.cpp +++ b/engines/saga/sndres.cpp @@ -225,6 +225,7 @@ bool SndRes::load(ResourceContext *context, uint32 resourceId, SoundBuffer &buff  	}  	Common::SeekableReadStream& readS = *file; +	bool uncompressedSound = false;  	if (soundResourceLength >= 8) {  		byte header[8]; @@ -242,7 +243,6 @@ bool SndRes::load(ResourceContext *context, uint32 resourceId, SoundBuffer &buff  			resourceType = kSoundShorten;  		} -		bool uncompressedSound = false;  		// If patch data exists for sound resource 4 (used in ITE intro), don't treat this sound as compressed  		// Patch data for this resource is in file p2_a.iaf or p2_a.voc  		if (_vm->getGameId() == GID_ITE && resourceId == 4 && context->getResourceData(resourceId)->patchData != NULL) @@ -277,7 +277,7 @@ bool SndRes::load(ResourceContext *context, uint32 resourceId, SoundBuffer &buff  			buffer.flags &= ~Audio::FLAG_16BITS;  		} else {  			// Voice files in newer ITE demo versions are OKI ADPCM (VOX) encoded -			if (!scumm_stricmp(context->fileName(), "voicesd.rsc")) +			if (!uncompressedSound && !scumm_stricmp(context->fileName(), "voicesd.rsc"))  				resourceType = kSoundVOX;  		}  	} | 
