Rust-SDL2 / rust-sdl2

SDL2 bindings for Rust
MIT License
2.71k stars 466 forks source link

Missing function to open specific audio device #1345

Open francisdb opened 10 months ago

francisdb commented 10 months ago

Below function is not available

https://wiki.libsdl.org/SDL2_mixer/Mix_OpenAudioDevice

Cobrand commented 10 months ago

It is implemented, but private, because you should use open_playback for output, and open_capture for inputs. Do you have a usecase where you cannot use those?

francisdb commented 10 months ago

I have a 7.1 usb sound card at index 7 I want to use. Not my default speakers.

Also on Linux the default device picked is not always the device you set up as default in pulseaudio / pipewire. Looks like it's just taking the order of alsa.