From: Lennart Poettering <mznyfn@0pointer.de>
To: alsa-devel@alsa-project.org
Subject: Re: Master vs. Front/Rear/LFE/... elements
Date: Thu, 7 May 2009 14:56:54 +0200 [thread overview]
Message-ID: <20090507125654.GB3968@tango.0pointer.de> (raw)
In-Reply-To: <s5h1vr1434g.wl%tiwai@suse.de>
On Thu, 07.05.09 12:30, Takashi Iwai (tiwai@suse.de) wrote:
>
> At Thu, 7 May 2009 11:09:16 +0100,
> Mark Brown wrote:
> >
> > On Thu, May 07, 2009 at 10:49:22AM +0200, Takashi Iwai wrote:
> >
> > > IMO, the best would be a total rewrite of the current mixer API, as I
> > > mentioned some times. Right now it's more complicated than needed,
> > > but not powerful enough to handle exceptional cases.
> >
> > Indeed - for example, something that allowed audio routing to be
> > expressed in the mixing API would be a very big win for embedded systems
> > too.
>
> Right. But this would also require some changes in the driver side,
> and it could be complicated.
>
> Actually, we had this kind of information in the time of ALSA 0.5.
> However, it ended up with too burden to the driver code because one
> had to write a comprehensive static graph in the driver code itself
> (generated by hand!). Also, some mixer elements are tightly coupled
> with certain audio components, but some are pretty abstract and hard
> to put into a graph. So, we reduced that in the newer API and
> implemented a straight array of control elements instead.
>
> Nevertheless, a sort of linking would be useful in addition to the
> current form. For example, coupling between the control element and
> the PCM stream is missing, too.
>
> Alternatively, we may have an external data outside the kernel
> driver. In that case, the data can be expressed more flexibly
> (XML? Oh yeah :)
That would actually work for me and I wouldn't even be that disgusted
by this usage of XML ;-)
>From the PA perspective I actually don't really need the full routing
of the sound card exposed. I always want to focus on actual end-user
use cases instead of exposing the full mixer capabilities. All I need
to know is which elements are in the pipeline from my PCM streams to a
specific output, resp. from a specific input to my PCM stream and a
more high-level idea what those elements actually mean. i.e. all I
need would be an API like this:
int snd_pcm_get_mixer_path(snd_pcm_t *pcm, snd_mixer_selem_id_t
path[], unsigned n);
This would simply return an array of mixer element ids that are in the
pipeline to the output, resp. from the input, ordered.
Then, a trivial API that allows me to identify what a mixer element's
use is would be all I need.
Lennart
--
Lennart Poettering Red Hat, Inc.
lennart [at] poettering [dot] net
http://0pointer.net/lennart/ GnuPG 0x1A015CC4
next prev parent reply other threads:[~2009-05-07 12:56 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-06 17:58 Master vs. Front/Rear/LFE/... elements Lennart Poettering
2009-05-07 8:49 ` Takashi Iwai
2009-05-07 10:09 ` Mark Brown
2009-05-07 10:30 ` Takashi Iwai
2009-05-07 10:53 ` Mark Brown
2009-05-07 12:56 ` Lennart Poettering [this message]
2009-05-07 13:10 ` Mark Brown
2009-05-07 13:12 ` Pavel Hofman
2009-05-08 6:36 ` Eliot Blennerhassett
2009-05-07 12:46 ` Lennart Poettering
2009-05-07 13:18 ` Takashi Iwai
2009-05-09 22:11 ` Lennart Poettering
2009-05-11 9:26 ` Takashi Iwai
2009-05-12 7:47 ` James Courtier-Dutton
2009-05-12 8:02 ` Jaroslav Kysela
2009-05-12 9:21 ` Mark Brown
2009-05-12 13:15 ` Lennart Poettering
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20090507125654.GB3968@tango.0pointer.de \
--to=mznyfn@0pointer.de \
--cc=alsa-devel@alsa-project.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox