diff options
| -rw-r--r-- | engines/mads/scene.cpp | 2 | ||||
| -rw-r--r-- | engines/tony/sound.cpp | 16 | ||||
| -rw-r--r-- | engines/tony/sound.h | 2 | ||||
| -rw-r--r-- | engines/tony/tony.cpp | 4 | 
4 files changed, 7 insertions, 17 deletions
diff --git a/engines/mads/scene.cpp b/engines/mads/scene.cpp index 2875bc0b56..cbc15b9da8 100644 --- a/engines/mads/scene.cpp +++ b/engines/mads/scene.cpp @@ -504,6 +504,8 @@ void  Scene::drawElements(ScreenTransition transitionType, bool surfaceFlag) {  	// Merge any identified dirty areas  	_dirtyAreas.merge(1, DIRTY_AREAS_SIZE); +	if (_posAdjust != Common::Point(0, 0)) +		warning("Adjust used %d %d", _posAdjust.x, _posAdjust.y);  	// Copy background for the dirty areas to the screen  	_dirtyAreas.copy(&_backgroundSurface, &_vm->_screen, _posAdjust); diff --git a/engines/tony/sound.cpp b/engines/tony/sound.cpp index 2a4eb826f3..fe4e0ab0e7 100644 --- a/engines/tony/sound.cpp +++ b/engines/tony/sound.cpp @@ -219,11 +219,10 @@ bool FPSfx::loadVoiceFromVDB(Common::File &vdbFP) {   * Opens a file and loads a sound effect.   *   * @param fileName         Sfx filename - * @param codec            CODEC used to uncompress the samples   *   * @returns                True is everything is OK, False otherwise   */ -bool FPSfx::loadFile(const char *fileName, uint32 codec) { +bool FPSfx::loadFile(const char *fileName) {  	if (!_soundSupported)  		return true; @@ -242,18 +241,7 @@ bool FPSfx::loadFile(const char *fileName, uint32 codec) {  	uint32 channels = file.readUint32LE();  	Common::SeekableReadStream *buffer = file.readStream(file.size() - file.pos()); - -	if (codec == FPCODEC_ADPCM) { -		_rewindableStream = Audio::makeADPCMStream(buffer, DisposeAfterUse::YES, 0, Audio::kADPCMDVI, rate, channels); -	} else { -		byte flags = Audio::FLAG_16BITS | Audio::FLAG_LITTLE_ENDIAN; - -		if (channels == 2) -			flags |= Audio::FLAG_STEREO; - -		_rewindableStream = Audio::makeRawStream(buffer, rate, flags, DisposeAfterUse::YES); -	} - +	_rewindableStream = Audio::makeADPCMStream(buffer, DisposeAfterUse::YES, 0, Audio::kADPCMDVI, rate, channels);  	_fileLoaded = true;  	return true;  } diff --git a/engines/tony/sound.h b/engines/tony/sound.h index 446dc68d80..50ef78ae0d 100644 --- a/engines/tony/sound.h +++ b/engines/tony/sound.h @@ -179,7 +179,7 @@ public:  	 * @returns             True is everything is OK, False otherwise  	 */ -	bool loadFile(const char *fileName, uint32 codec = FPCODEC_RAW); +	bool loadFile(const char *fileName);  	bool loadWave(Common::SeekableReadStream *stream);  	bool loadVoiceFromVDB(Common::File &vdbFP); diff --git a/engines/tony/tony.cpp b/engines/tony/tony.cpp index 2857bb93f8..b6ed51a84c 100644 --- a/engines/tony/tony.cpp +++ b/engines/tony/tony.cpp @@ -433,7 +433,7 @@ void TonyEngine::preloadSFX(int nChannel, const char *fn) {  	_theSound.createSfx(&_sfx[nChannel]); -	_sfx[nChannel]->loadFile(fn, FPCODEC_ADPCM); +	_sfx[nChannel]->loadFile(fn);  }  FPSfx *TonyEngine::createSFX(Common::SeekableReadStream *stream) { @@ -453,7 +453,7 @@ void TonyEngine::preloadUtilSFX(int nChannel, const char *fn) {  	_theSound.createSfx(&_utilSfx[nChannel]); -	_utilSfx[nChannel]->loadFile(fn, FPCODEC_ADPCM); +	_utilSfx[nChannel]->loadFile(fn);  	_utilSfx[nChannel]->setVolume(63);  }  | 
