[Scummvm-cvs-logs] CVS: scummvm/scumm sound.cpp,1.186,1.187

Max Horn fingolfin at users.sourceforge.net
Thu Jul 24 18:20:02 CEST 2003


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1:/tmp/cvs-serv12790/scumm

Modified Files:
	sound.cpp 
Log Message:
lots of mixer changes: replaced _volumeTable by _globalVolume (applying volume after resampling is more accurate); made more member vars of SoundMixer protected (and thus added some new getter methods); added (untested) support for a second (stereo) channel when playing MP3

Index: sound.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/sound.cpp,v
retrieving revision 1.186
retrieving revision 1.187
diff -u -d -r1.186 -r1.187
--- sound.cpp	23 Jul 2003 05:36:08 -0000	1.186
+++ sound.cpp	25 Jul 2003 01:19:13 -0000	1.187
@@ -1695,15 +1695,15 @@
 }
 
 int Sound::updateMP3CD() {
-	if (_dig_cd.playing == false)
+	if (!_dig_cd.playing)
 		return -1;
 
-	if (_scumm->_mixer->_channels[_dig_cd.index] == NULL) {
+	if (!_scumm->_mixer->isChannelUsed(_dig_cd.index)) {
 		warning("Error in MP3 decoding");
 		return -1;
 	}
 
-	if (!_scumm->_mixer->isActiveChannel(_dig_cd.index)) {
+	if (!_scumm->_mixer->isChannelActive(_dig_cd.index)) {
 		if (_dig_cd.num_loops == -1 || --_dig_cd.num_loops > 0)
 			playMP3CDTrack(_dig_cd.track, _dig_cd.num_loops, _dig_cd.start, _dig_cd.duration);
 		else





More information about the Scummvm-git-logs mailing list