[gst-devel] mixer track/device naming (again)

Ronald Bultje rbultje at ronald.bitfreak.net
Tue Nov 4 01:46:12 CET 2003


Hi Leif,

On Mon, 2003-11-03 at 23:00, Leif Johnson wrote:
> But in the first concept, the number of GStreamer pads on an element is
> the same as the number of tracks that it handles. In the second concept,
> though, the number of pads on the element has almost nothing to do with
> the number of devices in the physical output card ; for example, if I
> use an alsasink with two pads, my sound card automatically sends both
> signals through the PCM output device. This came up while reading the
> alsasink code, so I wanted to discuss.

The two concepts might be more similar than you'd think at first. I had
the same objection in the beginning, but it's not that bad when you
think about it. What does a mixer like adder do? It takes N inputs (one
per track, each with one GstPad), and outputs one stream, in this case
on a GstPad. What does osssrc do? It has N *hardware* inputs (so no
GstPad here), and one GstPad output. What does osssink do? It has one
input, one track (the PCM output), one GstPad sink, and a hardware
output (no GstPad). This all makes pretty much sense to me.

The issue is that we have to start thinking beyond pads.We had to start
thinking of interfaces as something that doesn't necessarily involve
GstPads, but something that involves what is going on inside the element
in a highly abstracted manner.

If you look at it that way, software mixing and hardware mixing are
pretty much the same, and the name 'track' for an input/output channel
(argh, naming...) makes pretty much sense. It's better than device, as
your patch proposes, since a device is really a hardware /dev/X entry
(or hw:X for alsa). It's not perfect, but there's just nothing better.

> Do you think we need two separate interfaces for these ?

No, I don't think so. I think that if we document this clear enough
(something I want to do after the Gnome-2.6 API freeze in december),
it's not so bad.

> make[5]: *** No rule to make target `ffmpeg/libavformat/flvdec.c', needed by `libavformat_la-flvdec.lo'. Stop.
> make[5]: Leaving directory `/home/leif/src/gst-plugins/gst-libs/ext/ffmpeg'

Hm, you're not the only one having compile issues, though it works for
me. Can you rm -fr gst-libs/ext/ffmpeg/ffmpeg and redo ./autogen.sh?

Ronald

-- 
Ronald Bultje <rbultje at ronald.bitfreak.net>
Linux Video/Multimedia developer





More information about the gstreamer-devel mailing list