All of lore.kernel.org
 help / color / mirror / Atom feed
* Determining the plugins being used?
@ 2011-09-12 19:16 Raymond Toy
  2011-09-12 20:31 ` Clemens Ladisch
  0 siblings, 1 reply; 4+ messages in thread
From: Raymond Toy @ 2011-09-12 19:16 UTC (permalink / raw)
  To: alsa-devel

Is there a way to determine the plugins being used?  I notice that
snd_pcm_dump produces information about the various plugins that are being
used.  In one of test case, aplay -v shows that it's using  a rate
conversion plugin, a slave for Direct Stream Mixing PCM, and finally, the
actual hardware PCM card.

For my application, it would be nice to know if we're using the pulse audio
plugin so that I can setup our code appropriately.  (The period interrupts
are not what we were expecting, so we need to use a different code path.)
 If we're using the dmix plugin, the period interrupts can match our
expectations, so we want to use a low-latency path.

What is the appropriate way to determine the plugins used?

Ray

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Determining the plugins being used?
  2011-09-12 19:16 Determining the plugins being used? Raymond Toy
@ 2011-09-12 20:31 ` Clemens Ladisch
  2011-09-12 21:04   ` Raymond Toy
  0 siblings, 1 reply; 4+ messages in thread
From: Clemens Ladisch @ 2011-09-12 20:31 UTC (permalink / raw)
  To: Raymond Toy; +Cc: alsa-devel

Raymond Toy wrote:
> Is there a way to determine the plugins being used?

Not really.  snd_pcm_type() gives you the topmost plugin's type.


Regards,
Clemens

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Determining the plugins being used?
  2011-09-12 20:31 ` Clemens Ladisch
@ 2011-09-12 21:04   ` Raymond Toy
  2011-09-13  6:54     ` Clemens Ladisch
  0 siblings, 1 reply; 4+ messages in thread
From: Raymond Toy @ 2011-09-12 21:04 UTC (permalink / raw)
  To: Clemens Ladisch; +Cc: alsa-devel

On Mon, Sep 12, 2011 at 1:31 PM, Clemens Ladisch <clemens@ladisch.de> wrote:

> Raymond Toy wrote:
> > Is there a way to determine the plugins being used?
>
> Not really.  snd_pcm_type() gives you the topmost plugin's type.
>
>
>
Bummer.  So the only hacky way is to look at the output of snd_pcm_dump,
then?

I will look into other ways to determine what I need to know about the
underlying audio interface.

Thanks,

Ray

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: Determining the plugins being used?
  2011-09-12 21:04   ` Raymond Toy
@ 2011-09-13  6:54     ` Clemens Ladisch
  0 siblings, 0 replies; 4+ messages in thread
From: Clemens Ladisch @ 2011-09-13  6:54 UTC (permalink / raw)
  To: Raymond Toy; +Cc: alsa-devel

Raymond Toy wrote:
> On Mon, Sep 12, 2011 at 1:31 PM, Clemens Ladisch <clemens@ladisch.de> wrote:
> > Raymond Toy wrote:
> > > Is there a way to determine the plugins being used?
> >
> > Not really.  snd_pcm_type() gives you the topmost plugin's type.

The pulse plugin typically is the topmost plugin.  However, you won't be
able to differentiate between 'plain' hw and dmix devices this way
because both often have a plug plugin on top.

> Bummer.  So the only hacky way is to look at the output of snd_pcm_dump,
> then?

Well, there is the even more hacky way of sifting through /proc/asound/
files to see who is accessing the hw device, but let's pretend I didn't
mention it ...

snd_pcm_dump() was designed for debugging only, but at the moment there
is no better way.


Regards,
Clemens

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-09-13  6:53 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-09-12 19:16 Determining the plugins being used? Raymond Toy
2011-09-12 20:31 ` Clemens Ladisch
2011-09-12 21:04   ` Raymond Toy
2011-09-13  6:54     ` Clemens Ladisch

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.