comparison libao2/ao_sdl.c @ 14849:d313f591d1a4

aos should respect the immed uninit flag (quit immediatly vs waiting till file is played to end).
author reimar
date Sun, 27 Feb 2005 23:06:32 +0000
parents cb5fbade8a5c
children 44c24de55f9d
comparison
equal deleted inserted replaced
14848:f92a93cfc508 14849:d313f591d1a4
291 291
292 // close audio device 292 // close audio device
293 static void uninit(int immed){ 293 static void uninit(int immed){
294 mp_msg(MSGT_AO,MSGL_V,"SDL: Audio Subsystem shutting down!\n"); 294 mp_msg(MSGT_AO,MSGL_V,"SDL: Audio Subsystem shutting down!\n");
295 if (!immed) 295 if (!immed)
296 while(buf_free() < BUFFSIZE - CHUNK_SIZE) 296 usec_sleep(get_delay() * 1000 * 1000);
297 usec_sleep(50000);
298 SDL_CloseAudio(); 297 SDL_CloseAudio();
299 SDL_QuitSubSystem(SDL_INIT_AUDIO); 298 SDL_QuitSubSystem(SDL_INIT_AUDIO);
300 } 299 }
301 300
302 // stop playing and empty buffers (for seeking/pause) 301 // stop playing and empty buffers (for seeking/pause)