mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-12-24 17:20:36 +00:00
make request pads work
Original commit message from CVS: make request pads work
This commit is contained in:
parent
9392c00442
commit
21595d5571
1 changed files with 4 additions and 4 deletions
|
@ -357,18 +357,18 @@ gst_alsa_request_new_pad (GstElement *element, GstPadTemplate *templ, const gcha
|
|||
}
|
||||
l = l->next;
|
||||
}
|
||||
newname = g_strdup (name);
|
||||
} else {
|
||||
l = this->pads;
|
||||
channel = 0;
|
||||
while (l) {
|
||||
if (GST_ALSA_PAD(l)->channel > channel)
|
||||
channel = GST_ALSA_PAD(l)->channel;
|
||||
if (GST_ALSA_PAD(l)->channel >= channel)
|
||||
channel = GST_ALSA_PAD(l)->channel + 1;
|
||||
l = l->next;
|
||||
}
|
||||
newname = g_strdup_printf (templ->name_template, channel);
|
||||
}
|
||||
|
||||
newname = g_strdup (name);
|
||||
|
||||
pad = g_new0(GstAlsaPad, 1);
|
||||
pad->channel = channel;
|
||||
pad->pad = gst_pad_new_from_template (templ, newname);
|
||||
|
|
Loading…
Reference in a new issue