comparison src/audio/windx5/SDL_dx5audio.c @ 2938:2929ed239d2a

Adjusted default choice of audio driver. If a driver can definitely see available devices, it is chosen. Otherwise, we'll take the first driver that initializes but saw no devices...this might be because it can't enumerate them, or there really aren't any available. This prevents the dsp driver from hogging control when there are no /dev/dsp* nodes (for example, on a Linux box with ALSA and no OSS emulation).
author Ryan C. Gordon <icculus@icculus.org>
date Thu, 01 Jan 2009 07:54:58 +0000
parents 99210400e8b9
children 8f4ed5ec2b06
comparison
equal deleted inserted replaced
2937:017d4334accf 2938:2929ed239d2a
506 impl->GetDeviceBuf = DSOUND_GetDeviceBuf; 506 impl->GetDeviceBuf = DSOUND_GetDeviceBuf;
507 impl->CloseDevice = DSOUND_CloseDevice; 507 impl->CloseDevice = DSOUND_CloseDevice;
508 impl->Deinitialize = DSOUND_Deinitialize; 508 impl->Deinitialize = DSOUND_Deinitialize;
509 impl->OnlyHasDefaultOutputDevice = 1; /* !!! FIXME */ 509 impl->OnlyHasDefaultOutputDevice = 1; /* !!! FIXME */
510 510
511 /* !!! FIXME: not right for device enum? */
511 return 1; 512 return 1;
512 } 513 }
513 514
514 AudioBootStrap DSOUND_bootstrap = { 515 AudioBootStrap DSOUND_bootstrap = {
515 "dsound", WINDOWS_OS_NAME "DirectSound", DSOUND_Init, 0 516 "dsound", WINDOWS_OS_NAME "DirectSound", DSOUND_Init, 0