Request pads names

Sérgio Agostinho sergio.r.agostinho at gmail.com
Thu Apr 30 01:21:49 PDT 2015


Bump.

Come on guys, somebody must have faced this problem before. Is it possible
to do what I've mentioned.?

Cheers

2015-04-28 11:05 GMT+02:00 Sérgio Agostinho <sergio.r.agostinho at gmail.com>:

> Hi everyone,
>
> Normally when you request a pad from a tee, you specify the name of the
> template 'src_%u' and then a new pads gets created with a name
>
> src_0
> src_1
> src_2
> etc...
>
> This time I was trying to specify the name of the pad myself, i.e. I
> wanted the first request pad created to be named 'src_1', the second one
> 'src_11', etc....
>
> Is this possible? If so, how do I achieve this?
>
> I've listed below all my unsuccessful attempts so far:
>
> 1 -
> gst_element_get_request_pad(tee, "src_1");
>
> 2 -
> tmpl = gst_element_class_get_pad_template (GST_ELEMENT_GET_CLASS (tee),
> "src_%u");
> gst_element_request_pad(tee, tmpl, "src_1", NULL);
>
> 3 -
> tmpl_gen = gst_element_class_get_pad_template (GST_ELEMENT_GET_CLASS
> (tee), "src_%u");
> caps = gst_pad_template_get_caps(tmpl_gen);
> tmpl = gst_pad_template_new(s,GST_PAD_TEMPLATE_DIRECTION(tmpl_gen),
> GST_PAD_TEMPLATE_PRESENCE(tmpl_gen), caps);
> gst_element_request_pad(tee, tmpl, "src_1", NULL);
>
>
> Cheers,
> Sérgio
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20150430/afb3ca76/attachment.html>


More information about the gstreamer-devel mailing list