<div dir="ltr"><span style="font-size:12.8000001907349px">The pad is unlinked, there's is no data flowing trough it, there are no negotiated capabilities at this point. I think the pads needs to be linked and to have pushed at least some buffers for the caps event to flow downstream. The experts might provide more insight on what actually happens. </span><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">I find it strange that removing and creating a new pad makes any difference in the return value of gst_pad_get_negotiated_caps(), under the conditions you described. </span></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">If you run </span><span style="font-size:12.8000001907349px">gst_pad_get_negotiated_caps() before unlinking you should get a caps object which should be persistent until you unref it. If that fails you can always convert the caps to string and use further down the road when you need.</span></div><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">As a final note, I'm not really sure on what are you trying to do but I get the feeling you're asking the "wrong questions". </span></div><div><span style="font-size:12.8000001907349px"><br></span></div></div><div class="gmail_extra"><br><div class="gmail_quote">2015-02-25 13:39 GMT+01:00 Yogesh Tyagi <span dir="ltr"><<a href="mailto:yogesh.bit2006@gmail.com" target="_blank">yogesh.bit2006@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Yes I tested it and it returns NULL. I wanted to know the reason for this.In my code when <span style="font-size:12.8000001907349px">gst_pad_get_negotiated_caps() retuens NULL, I remove the source pad and add new pad again. I don't want to do that. Is it possible for source pad to retain old caps somehow?</span><div><span style="font-size:12.8000001907349px"><br></span></div><div><span style="font-size:12.8000001907349px">Thanks,</span></div><div><span style="font-size:12.8000001907349px">Yogesh</span></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Feb 25, 2015 at 5:45 PM, Sérgio Agostinho <span dir="ltr"><<a href="mailto:sergio.r.agostinho@gmail.com" target="_blank">sergio.r.agostinho@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">This is something you can actually test yourself. <div>The equivalent method in gstreamer 1.0 <font face="monospace, monospace">gst_pad_get_current_caps()</font> will return <font face="monospace, monospace">NULL</font>.<div><br></div><div>Cheers, </div><div><span><font color="#888888">Sérgio</font></span><div><div><br><div class="gmail_extra"><br><div class="gmail_quote">2015-02-25 11:12 GMT+01:00 Yogesh Tyagi <span dir="ltr"><<a href="mailto:yogesh.bit2006@gmail.com" target="_blank">yogesh.bit2006@gmail.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Thanks for the answer. What will gst_pad_get_negotiated_caps() return for an element's source pad which is linked again to pipeline (after unlinking)?<div><div><br></div><div>Thanks,</div><div>Yogesh<br><div class="gmail_extra"><div class="gmail_quote"><div><div>On Tue, Feb 24, 2015 at 1:38 PM, Sebastian Dröge <span dir="ltr"><<a href="mailto:sebastian@centricular.com" target="_blank">sebastian@centricular.com</a>></span> wrote:<br></div></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div><div><span>On Mo, 2015-02-23 at 19:07 +0530, Yogesh Tyagi wrote:<br>
> Hi,<br>
><br>
> Can somebody please help me understand whether an element goes to all the<br>
> downward state changes(PLAYING to NULL) when I call gst_bin_remove to<br>
> remove that element from the pipeline?<br>
<br>
</span>It doesn't, the state stays the same.<br>
<span><br>
> What happens to the source pads of the element it this case?<br>
<br>
</span>They are still there :) But if they were linked to something else, the<br>
source pads would be unlinked now.<br>
<div><div><br>
> I want to take deceision of adding a new source pad to this element<br>
> depeneding upon existance of the old source pad of this element before it<br>
> was unlinked from the pipeline.<br>
<br>
</div></div><span><font color="#888888">--<br>
Sebastian Dröge, Centricular Ltd · <a href="http://www.centricular.com" target="_blank">http://www.centricular.com</a><br>
</font></span><br></div></div>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br></div></div></div></div>
<br>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br></div></div></div></div></div></div>
<br>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org" target="_blank">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel" target="_blank">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
<br></blockquote></div><br></div>