[Scummvm-cvs-logs] SF.net SVN: scummvm:[47362] scummvm/trunk/engines/sci
m_kiewitz at users.sourceforge.net
m_kiewitz at users.sourceforge.net
Mon Jan 18 23:39:57 CET 2010
Revision: 47362
http://scummvm.svn.sourceforge.net/scummvm/?rev=47362&view=rev
Author: m_kiewitz
Date: 2010-01-18 22:39:56 +0000 (Mon, 18 Jan 2010)
Log Message:
-----------
SCI: dont set dataInc selector inside updateCues when dataInc is not available
Modified Paths:
--------------
scummvm/trunk/engines/sci/sci.cpp
scummvm/trunk/engines/sci/sound/soundcmd.cpp
scummvm/trunk/engines/sci/sound/soundcmd.h
Modified: scummvm/trunk/engines/sci/sci.cpp
===================================================================
--- scummvm/trunk/engines/sci/sci.cpp 2010-01-18 21:29:43 UTC (rev 47361)
+++ scummvm/trunk/engines/sci/sci.cpp 2010-01-18 22:39:56 UTC (rev 47362)
@@ -165,7 +165,7 @@
SciVersion soundVersion = _gamestate->detectDoSoundType();
- _gamestate->_soundCmd = new SoundCommandParser(_resMan, segMan, _audio, soundVersion);
+ _gamestate->_soundCmd = new SoundCommandParser(_resMan, segMan, _kernel, _audio, soundVersion);
// Assign default values to the config manager, in case settings are missing
ConfMan.registerDefault("undither", "true");
Modified: scummvm/trunk/engines/sci/sound/soundcmd.cpp
===================================================================
--- scummvm/trunk/engines/sci/sound/soundcmd.cpp 2010-01-18 21:29:43 UTC (rev 47361)
+++ scummvm/trunk/engines/sci/sound/soundcmd.cpp 2010-01-18 22:39:56 UTC (rev 47362)
@@ -126,8 +126,8 @@
}
#endif
-SoundCommandParser::SoundCommandParser(ResourceManager *resMan, SegManager *segMan, AudioPlayer *audio, SciVersion soundVersion) :
- _resMan(resMan), _segMan(segMan), _audio(audio), _soundVersion(soundVersion) {
+SoundCommandParser::SoundCommandParser(ResourceManager *resMan, SegManager *segMan, Kernel *kernel, AudioPlayer *audio, SciVersion soundVersion) :
+ _resMan(resMan), _segMan(segMan), _kernel(kernel), _audio(audio), _soundVersion(soundVersion) {
#ifdef USE_OLD_MUSIC_FUNCTIONS
// The following hack is needed to ease the change from old to new sound code (because the new sound code does not use SfxState)
@@ -840,7 +840,8 @@
// Update MIDI slots
if (musicSlot->signal == 0) {
if (musicSlot->dataInc != GET_SEL32V(_segMan, obj, dataInc)) {
- PUT_SEL32V(_segMan, obj, dataInc, musicSlot->dataInc);
+ if (_kernel->_selectorCache.dataInc > -1)
+ PUT_SEL32V(_segMan, obj, dataInc, musicSlot->dataInc);
PUT_SEL32V(_segMan, obj, signal, musicSlot->dataInc + 127);
}
} else {
Modified: scummvm/trunk/engines/sci/sound/soundcmd.h
===================================================================
--- scummvm/trunk/engines/sci/sound/soundcmd.h 2010-01-18 21:29:43 UTC (rev 47361)
+++ scummvm/trunk/engines/sci/sound/soundcmd.h 2010-01-18 22:39:56 UTC (rev 47362)
@@ -46,7 +46,7 @@
class SoundCommandParser {
public:
- SoundCommandParser(ResourceManager *resMan, SegManager *segMan, AudioPlayer *audio, SciVersion soundVersion);
+ SoundCommandParser(ResourceManager *resMan, SegManager *segMan, Kernel *kernel, AudioPlayer *audio, SciVersion soundVersion);
~SoundCommandParser();
enum {
@@ -81,6 +81,7 @@
SoundCommandContainer _soundCommands;
ResourceManager *_resMan;
SegManager *_segMan;
+ Kernel *_kernel;
#ifdef USE_OLD_MUSIC_FUNCTIONS
SfxState *_state;
int _midiCmd, _controller, _param;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list