[MPlayer-cvslog] CVS: main/libao2 ao_alsa.c, 1.17, 1.18 ao_nas.c, 1.22, 1.23 ao_sdl.c, 1.40, 1.41 ao_sgi.c, 1.11, 1.12

Reimar Döffinger CVS syncmail at mplayerhq.hu
Mon Feb 28 00:06:34 CET 2005


CVS change done by Reimar Döffinger CVS

Update of /cvsroot/mplayer/main/libao2
In directory mail:/var2/tmp/cvs-serv9839/libao2

Modified Files:
	ao_alsa.c ao_nas.c ao_sdl.c ao_sgi.c 
Log Message:
aos should respect the immed uninit flag (quit immediatly vs waiting till file
is played to end).


Index: ao_alsa.c
===================================================================
RCS file: /cvsroot/mplayer/main/libao2/ao_alsa.c,v
retrieving revision 1.17
retrieving revision 1.18
diff -u -r1.17 -r1.18
--- ao_alsa.c	30 Jan 2005 09:16:41 -0000	1.17
+++ ao_alsa.c	27 Feb 2005 23:06:32 -0000	1.18
@@ -687,6 +687,9 @@
   if (alsa_handler) {
     int err;
 
+    if (!immed)
+      snd_pcm_drain(alsa_handler);
+
     if (!ao_noblock) {
       if ((err = snd_pcm_drop(alsa_handler)) < 0)
 	{

Index: ao_nas.c
===================================================================
RCS file: /cvsroot/mplayer/main/libao2/ao_nas.c,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -r1.22 -r1.23
--- ao_nas.c	12 Jan 2005 22:07:44 -0000	1.22
+++ ao_nas.c	27 Feb 2005 23:06:32 -0000	1.23
@@ -482,6 +482,7 @@
 	mp_msg(MSGT_AO, MSGL_DBG3, "ao_nas: uninit()\n");
 
 	nas_data->expect_underrun = 1;
+	if (!immed)
 	while (nas_data->state != AuStateStop) usleep(1000);
 	nas_data->stop_thread = 1;
 	pthread_join(nas_data->event_thread, NULL);

Index: ao_sdl.c
===================================================================
RCS file: /cvsroot/mplayer/main/libao2/ao_sdl.c,v
retrieving revision 1.40
retrieving revision 1.41
diff -u -r1.40 -r1.41
--- ao_sdl.c	28 Dec 2004 19:11:14 -0000	1.40
+++ ao_sdl.c	27 Feb 2005 23:06:32 -0000	1.41
@@ -293,8 +293,7 @@
 static void uninit(int immed){
 	mp_msg(MSGT_AO,MSGL_V,"SDL: Audio Subsystem shutting down!\n");
 	if (!immed)
-	while(buf_free() < BUFFSIZE - CHUNK_SIZE)
-		usec_sleep(50000);
+	  usec_sleep(get_delay() * 1000 * 1000);
 	SDL_CloseAudio();
 	SDL_QuitSubSystem(SDL_INIT_AUDIO);
 }

Index: ao_sgi.c
===================================================================
RCS file: /cvsroot/mplayer/main/libao2/ao_sgi.c,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- ao_sgi.c	28 Dec 2004 19:11:14 -0000	1.11
+++ ao_sgi.c	27 Feb 2005 23:06:32 -0000	1.12
@@ -126,6 +126,7 @@
   mp_msg(MSGT_AO, MSGL_INFO, MSGTR_AO_SGI_Uninit);
 
   if (ao_port) {
+    if (!immed)
     while(alGetFilled(ao_port) > 0) sginap(1);  
     alClosePort(ao_port);
     alFreeConfig(ao_config);




More information about the MPlayer-cvslog mailing list