releasing a request pad
Sebastian Dröge
slomo at circular-chaos.org
Mon Sep 2 03:46:33 PDT 2013
On Mo, 2013-09-02 at 03:30 -0700, rashmi wrote:
> I have in my code requested for a tee pad using:
> srcpad = gst_element_get_request_pad (tee,"src0");
> g_print ("Obtained request pad %s for tee.\n", gst_pad_get_name
> (tee_video_pad));
> which is linked to some bin and later on released by:
> gst_element_release_request_pad (tee, srcpad);
> At some later point in my code i again request a pad for tee
> srcpad = gst_element_get_request_pad (tee,"src0");
> g_print ("Obtained request pad %s for tee.\n", gst_pad_get_name
> (tee_video_pad));
>
> This time however the "Obtained request pad for tee shows it got src1 for
> tee".
> I again release the pad and request it yet again with the same statement:
> srcpad = gst_element_get_request_pad (tee,"src0");
> for third time.Again I find the "Obtained request pad for tee as src2"(i.e
> incremented by 1).
> Does it mean that the requested pad for tee is never freed by the statement
> :
> gst_element_release_request_pad (tee, srcpad);
>
> If no then how can I free a pad that was previously requested.I have tried
> gst_element_remove_pad and gst_object _unref(srcpad). both with no success.
It is released by that but tee has an internal counter that is used for
the pad name for simplicty. So you will get a new name each time a pad
is requested.
More information about the gstreamer-devel
mailing list