PortAudio / portaudio

PortAudio is a cross-platform, open-source C language library for real-time audio input and output.
Other
1.37k stars 286 forks source link

How to share a mic with ALSA application (dsnoop) #747

Open danieljlevine opened 1 year ago

danieljlevine commented 1 year ago

Hey there. It looks like portaudio doesn't list ALSA dsnoop capture devices because they are specified in the pa_linux_alsa.c IgnorePlugin():

/ Disregard some standard plugins / static int IgnorePlugin( const char pluginId ) { static const char ignoredPlugins[] = {"hw", "plughw", "plug", "dsnoop", "tee", "file", "null", "shm", "cards", "rate_convert", NULL}; ...

I want to share the audio capture device with another application that is using the ALSA dsnoop device. I'm assuming the dnoop device is being ignored for a great reason. So how would I share such an audio capture, device if can't use dsnoop type devices?

RossBencina commented 1 year ago

I don't know why it's ignored. Have you tried removing it from the ignore list? does it work then?

RossBencina commented 1 year ago

For information:

dsnoop is the equivalent of the dmix plugin, but for recording sound. The dsnoop plugin allows several applications to record from the same device simultaneously.

https://alsa.opensrc.org/Dsnoop