[Scummvm-cvs-logs] CVS: scummvm/bs2/driver d_sound.cpp,1.27,1.28

Torbj?rn Andersson eriktorbjorn at users.sourceforge.net
Tue Sep 2 06:55:59 CEST 2003


Update of /cvsroot/scummvm/scummvm/bs2/driver
In directory sc8-pr-cvs1:/tmp/cvs-serv25536

Modified Files:
	d_sound.cpp 
Log Message:
Use the new per-channel pausing. This allows us to play the music for the
in-game dialogs.


Index: d_sound.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/bs2/driver/d_sound.cpp,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -d -r1.27 -r1.28
--- d_sound.cpp	2 Sep 2003 12:55:20 -0000	1.27
+++ d_sound.cpp	2 Sep 2003 13:50:45 -0000	1.28
@@ -627,13 +627,13 @@
 }
 
 uint8 Sword2Sound::IsSpeechMute(void) {
-	return (speechMuted);
+	return speechMuted;
 }
 
 int32 Sword2Sound::PauseSpeech(void) {
 	if (GetSpeechStatus() == RDSE_SAMPLEPLAYING) {
 		speechPaused = 1;
-		g_engine->_mixer->pauseChannels(true);
+		g_engine->_mixer->pauseHandle(soundHandleSpeech, true);
 	}
 	return(RD_OK);
 }
@@ -641,7 +641,7 @@
 int32 Sword2Sound::UnpauseSpeech(void) {
 	if (speechPaused) {
 		speechPaused = 0;
-		g_engine->_mixer->pauseChannels(false);
+		g_engine->_mixer->pauseHandle(soundHandleSpeech, false);
 	}
 	return(RD_OK);
 }
@@ -1122,7 +1122,7 @@
 	if (!fxPaused) {
 		for (i = 0; i < MAXFX; i++) {
 			if (fxId[i]) {
-				g_engine->_mixer->pauseChannels(true);
+				g_engine->_mixer->pauseHandle(soundHandleFx[i], true);
 				fxiPaused[i] = 1;
 			} else {
 				fxiPaused[i] = 0;
@@ -1139,7 +1139,7 @@
 	if (!fxPaused) {
 		for (i = 0; i<MAXFX; i++) {
 			if ((fxId[i]) && (fxId[i] != (int32) 0xfffffffe)) {
-				g_engine->_mixer->stopHandle(soundHandleFx[i]);
+				g_engine->_mixer->pauseHandle(soundHandleFx[i], true);
 				fxiPaused[i] = 1;
 			} else {
 				fxiPaused[i] = 0;
@@ -1156,7 +1156,7 @@
 	if (fxPaused) {
 		for (i = 0; i < MAXFX; i++) {
 			if (fxiPaused[i] && fxId[i]) {
-				g_engine->_mixer->pauseChannels(false);
+				g_engine->_mixer->pauseHandle(soundHandleFx[i], false);
 			}
 		}
 		fxPaused = 0;
@@ -2256,7 +2256,7 @@
 		for (i = 0; i < 2; i++) {
 			if (musStreaming[i]) {
 				musicPaused[i] = TRUE;
-				g_engine->_mixer->pauseChannels(true);
+				g_engine->_mixer->pauseHandle(soundHandleMusic[i], true);
 			} else {
 				musicPaused[i] = FALSE;
 			}
@@ -2271,7 +2271,7 @@
 	if (soundOn) {
 		for (i = 0; i < 2; i++) {
 			if (musicPaused[i]) {
-				g_engine->_mixer->pauseChannels(false);
+				g_engine->_mixer->pauseHandle(soundHandleMusic[i], false);
 				musicPaused[i] = FALSE;
 			}
 		}





More information about the Scummvm-git-logs mailing list