Open W3AXL opened 11 months ago
I am able to test this as soon as changes are ready - unfortunately my C isn't terribly good otherwise I'd take a crack at writing the PR myself.
The most basic setup to test this would be to create (or modify) your ~/.asoundrc
file to include a simple dsnoop
PCM definition (as explained here):
pcm.dsnooptest {
type dsnoop
slave {
pcm "hw:0,0"
channels 2
}
}
of course using the correct device definition for your system in place of hw:0,0
Then you can run the testaudiocapture
example program. Currently I get the following error when it attempts to open the PCM dsnoop device:
$ ./testaudiocapture line_in_11
INFO: Using audio driver: alsa
INFO: Capture device #0: 'USB Audio Device, USB Audio'
INFO: Capture device #1: 'US-16x08, USB Audio'
INFO: Opening default playback device...
INFO: Opening capture device 'line_in_11'...
ERROR: Couldn't open an audio device for capture: No such device.!
Can you check https://github.com/libsdl-org/SDL/pull/9753 and see if it works for you?
Hello all!
Trying to use SDL2 for my application (well, technically SDL2 via the SipsorceryMedia.SDL2 C# library) and I'm hitting an issue on my linux test system.
Using the device names from
aplay -l
/arecord -l
, everything works fine. However, I use ALSA dmix & dsnoop devices to split/combine multiple PCM audio channels to a single 16-in/8-out audio interface. These "software devices" are defined in my .asoundrc file like so:And show up with the capital "L" aplay/arecord switches as follows:
However, using these device names in
OpenAudioDevice()
returns 0. Is it possible to use these "software" ALSA audio devices with SDL2, or are we restricted to hardware devices only?