comparison src/audio/macrom/SDL_romaudio.c @ 3846:66fb40445587 SDL-ryan-multiple-audio-device

Removed distinction between "available" and "init" in audio backends, since both had to be checked for success as a pair at the higher level and several of the Available methods were just always-succeed placeholders anyhow. Now the availability check is done in the init code, and the higher level tries all possible drivers until one manages to initialize successfully.
author Ryan C. Gordon <icculus@icculus.org>
date Tue, 17 Oct 2006 09:09:21 +0000
parents 29e83f221c62
children
comparison
equal deleted inserted replaced
3845:ee5dfa7f7993 3846:66fb40445587
47 47
48 #include "SDL_audio.h" 48 #include "SDL_audio.h"
49 #include "../SDL_audio_c.h" 49 #include "../SDL_audio_c.h"
50 #include "../SDL_sysaudio.h" 50 #include "../SDL_sysaudio.h"
51 #include "SDL_romaudio.h" 51 #include "SDL_romaudio.h"
52
53 static int
54 SNDMGR_Available(void)
55 {
56 return (1);
57 }
58
59 52
60 #pragma options align=power 53 #pragma options align=power
61 54
62 static volatile SInt32 audio_is_locked = 0; 55 static volatile SInt32 audio_is_locked = 0;
63 static volatile SInt32 need_to_mix = 0; 56 static volatile SInt32 need_to_mix = 0;
318 311
319 return 1; 312 return 1;
320 } 313 }
321 314
322 AudioBootStrap SNDMGR_bootstrap = { 315 AudioBootStrap SNDMGR_bootstrap = {
323 "sndmgr", SDL_MACOS_NAME " SoundManager", 316 "sndmgr", SDL_MACOS_NAME " SoundManager", SNDMGR_Init, 0
324 SNDMGR_Available, SNDMGR_Init, 0
325 }; 317 };
326 318
327 /* vi: set ts=4 sw=4 expandtab: */ 319 /* vi: set ts=4 sw=4 expandtab: */