libretro / RetroArch

Cross-platform, sophisticated frontend for the libretro API. Licensed GPLv3.
http://www.libretro.com
GNU General Public License v3.0
10.05k stars 1.81k forks source link

SDL2 NO AUDIO #13799

Open Ir1s07 opened 2 years ago

Ir1s07 commented 2 years ago

so, in retro arch i switched to audio driver "sdl2" cause it increases my fps massively. but i get no audio. I have windows audio but not retroarch audio. not in game or in menus. any tips?

keithbowes commented 2 years ago

SDL2 shouldn't have better performance. It should have worse (other emulators advise to use SDL only as a last resort). SDL2 uses the OS's underlying sound system (see https://wiki.libsdl.org/FAQUsingSDL#how_do_i_choose_a_specific_audio_driver). Maybe your version was compiled without SDL2 (the last time I checked, the prebuilt Windows versions don't include SDL or SDL2 support) and it's using a nonfunctional audio driver instead. When I try to use a Windows version with audio_driver set to sdl2 in WINE, it tries to use xaudio but complains that it can't load xaudio2_7.dll (it works fine with dsound and wasapi, though). That may or may not be the case for native Windows.

I suppose you'd have to start with retroarch -v to know exactly what's going on. For example, I get:

[INFO] [Video]: Found display server: "win32".
[ERROR] Couldn't find any audio driver named "sdl2"
[INFO] Available audio drivers are:
[INFO]  xaudio
[INFO]  dsound
[INFO]  wasapi
[INFO]  null
[WARN] Going to default to first audio driver...

followed by the WINE error:

00d8:err:ole:apartment_add_dll couldn't load in-process dll L"C:\\windows\\system32\\xaudio2_7.dll"