changeset 1091:06fd776f6b59

Lock callback on pause, unlock on resume.
author atmosfear
date Sun, 10 Jun 2001 23:43:37 +0000
parents fd0d77973d08
children bd2b9f63adf1
files libao2/ao_sdl.c
diffstat 1 files changed, 5 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/libao2/ao_sdl.c	Sun Jun 10 23:40:20 2001 +0000
+++ b/libao2/ao_sdl.c	Sun Jun 10 23:43:37 2001 +0000
@@ -230,7 +230,7 @@
 // stop playing and empty buffers (for seeking/pause)
 static void reset(){
 
-	printf("SDL: reset called!\n");	
+	//printf("SDL: reset called!\n");	
 
 	/* Reset ring-buffer state */
 	buf_read=0;
@@ -247,16 +247,16 @@
 static void audio_pause()
 {
 
-	printf("SDL: audio_pause called!\n");	
+	//printf("SDL: audio_pause called!\n");	
+	SDL_LockAudio();
 	
-	// for now, just call reset();
-	//reset();
-
 }
 
 // resume playing, after audio_pause()
 static void audio_resume()
 {
+	//printf("SDL: audio_resume called!\n");	
+	SDL_UnlockAudio();
 }