[alsa-devel] Exclusive access to capture device
smcnam at gmail.com
Sun Jun 24 22:31:19 CEST 2012
If you open a hardware device that doesn't have hardware mixing, it's
*always* exclusive access. But the driver can support hardware mixing
for sound cards that supply it, which makes it non-exclusive.
Also, if you open a soft device that has software mixing, such as the
pulseaudio plugin or dsnoop, it won't be exclusive.
Hopefully you aren't writing a desktop application, because distros
and users generally abhor the notion of an application "hogging" the
sound device for any reason, and would prefer that all access be
non-exclusive. But if you're coding for an embedded device, then I can
understand this approach.
Then again, if you're working in the embedded space, you have full
control over the entire software and hardware stack, right? So make
sure that the device you open, e.g. hw:0 or whatever, is a driver that
doesn't support hardware mixing. Problem solved; your access is
On Sun, Jun 24, 2012 at 4:17 PM, Guy Rutenberg <guyrutenberg at gmail.com> wrote:
> Is there a way to open a capture device exclusively? E.g. I want to capture
> audio and be sure no other application can capture from that device at the
> same time.
> I've went through the API and searched the mailing list and haven't found a
> way to do so.
> Thanks a lot,
> Alsa-devel mailing list
> Alsa-devel at alsa-project.org
More information about the Alsa-devel