[Scummvm-cvs-logs] SF.net SVN: scummvm:[46885] scummvm/trunk/engines/sci/sfx
thebluegr at users.sourceforge.net
thebluegr at users.sourceforge.net
Sat Jan 2 16:02:41 CET 2010
Revision: 46885
http://scummvm.svn.sourceforge.net/scummvm/?rev=46885&view=rev
Author: thebluegr
Date: 2010-01-02 15:02:41 +0000 (Sat, 02 Jan 2010)
Log Message:
-----------
SCI/new music code: cleaned up cmdUpdateCues and changed the SCI reverb(?) SysEx in parseNextEvent() to a NOP for now, till its sorted out
Modified Paths:
--------------
scummvm/trunk/engines/sci/sfx/midiparser.cpp
scummvm/trunk/engines/sci/sfx/soundcmd.cpp
Modified: scummvm/trunk/engines/sci/sfx/midiparser.cpp
===================================================================
--- scummvm/trunk/engines/sci/sfx/midiparser.cpp 2010-01-02 14:11:38 UTC (rev 46884)
+++ scummvm/trunk/engines/sci/sfx/midiparser.cpp 2010-01-02 15:02:41 UTC (rev 46885)
@@ -133,10 +133,7 @@
// http://wiki.scummvm.org/index.php/SCI/Specifications/Sound/SCI0_Resource_Format#Status_Reference
// Also, sci/sfx/iterator/iterator.cpp, function BaseSongIterator::parseMidiCommand()
switch (info.basic.param1) {
- case 0x50: // set volume
- // This is documented to be "reverb", but it looks like channel
- // volume, at least in SCI11, so treat it as such
- _pSnd->volume = info.basic.param2;
+ case 0x50: // set reverb
break;
case 0x52: // set hold
_pSnd->hold = info.basic.param2;
Modified: scummvm/trunk/engines/sci/sfx/soundcmd.cpp
===================================================================
--- scummvm/trunk/engines/sci/sfx/soundcmd.cpp 2010-01-02 14:11:38 UTC (rev 46884)
+++ scummvm/trunk/engines/sci/sfx/soundcmd.cpp 2010-01-02 15:02:41 UTC (rev 46885)
@@ -785,9 +785,7 @@
musicSlot->sampleLoopCounter = currentLoopCounter;
}
if (!mixer->isSoundHandleActive(musicSlot->hCurrentAud)) {
- musicSlot->ticker = SIGNAL_OFFSET;
- musicSlot->signal = SIGNAL_OFFSET;
- musicSlot->status = kSoundStopped;
+ cmdStopSound(obj, 0);
} else {
musicSlot->ticker = (uint16)(mixer->getSoundElapsedTime(musicSlot->hCurrentAud) * 0.06);
}
@@ -796,33 +794,28 @@
mixer->setChannelVolume(musicSlot->hCurrentAud, musicSlot->volume);
musicSlot->fadeVolumeSet = false;
}
+ } else {
+ switch (musicSlot->signal) {
+ case 0:
+ if (musicSlot->dataInc != GET_SEL32V(_segMan, obj, dataInc)) {
+ PUT_SEL32V(_segMan, obj, dataInc, musicSlot->dataInc);
+ PUT_SEL32V(_segMan, obj, signal, musicSlot->dataInc + 127);
+ }
+ break;
+ case SIGNAL_OFFSET:
+ cmdStopSound(obj, 0);
+ break;
+ default:
+ // Sync the signal of the sound object
+ PUT_SEL32V(_segMan, obj, signal, musicSlot->signal);
+ break;
+ }
}
- switch (musicSlot->signal) {
- case 0:
- if (musicSlot->dataInc != GET_SEL32V(_segMan, obj, dataInc)) {
- PUT_SEL32V(_segMan, obj, dataInc, musicSlot->dataInc);
- PUT_SEL32V(_segMan, obj, signal, musicSlot->dataInc + 127);
- }
- break;
- case SIGNAL_OFFSET:
- cmdStopSound(obj, 0);
- break;
- default:
- // Sync the signal of the sound object
- PUT_SEL32V(_segMan, obj, signal, musicSlot->signal);
- break;
- }
// Sync loop selector for SCI0
if (_soundVersion <= SCI_VERSION_0_LATE)
PUT_SEL32V(_segMan, obj, loop, musicSlot->loop);
- // Signal the game when a digital sound effect is done playing
- if (musicSlot->pStreamAud && musicSlot->status == kSoundStopped &&
- musicSlot->signal == SIGNAL_OFFSET) {
- cmdStopSound(obj, 0);
- }
-
musicSlot->signal = 0;
if (_soundVersion >= SCI_VERSION_1_EARLY) {
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