Hi all,
I need to add a signal to my pipeline... This is my pipeline: pipeline = gst_parse_launch("rtspsrc location=rtsp://<ipaddress>/<url> latency=10 ! rtph264depay ! avdec_h264 ! autovideosink", &error); and I need to implement the callback for "on-sdp" signal in grtsp element. Someone can explain me how do that? Thanks a lot Elio _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On Mo, 2016-03-14 at 12:33 +0100, elio francesconi wrote:
> Hi all, > I need to add a signal to my pipeline... > This is my pipeline: > pipeline = gst_parse_launch("rtspsrc > location=rtsp://<ipaddress>/<url> latency=10 ! rtph264depay ! > avdec_h264 ! autovideosink", &error); > and I need to implement the callback for "on-sdp" signal in grtsp > element. > Someone can explain me how do that? Thanks a lot Give a name to rtspsrc by setting the name property, and then use gst_bin_get_by_name() on the pipeline to get a pointer to the rtspsrc instance. Then you can connect to the signal. -- Sebastian Dröge, Centricular Ltd · http://www.centricular.com _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel signature.asc (968 bytes) Download Attachment |
Hi Sebastian thanks for your hint. As you suggested I got the rtspBin element using: GstElement * rtspBin = gst_bin_get_by_name(GST_BIN(pipeline), "rtspsrc0"); AFAIK the name is "rtspsrc0" and changes everytime I create a pipeline, it impossible for me detect the name because the second time the name is "rtspsrc1" the third "rtspsrc2"... Which is the correct behaviour to detect the name? Or.. Can I get the rtspBin using gst_bin_get_by_interface? In this case I can find files to include to be defined GST_TYPE_RTSPSRC (I'm using GStreamer library 1.6.1 under iOS) This is my code. GstElement * rtspBin = gst_bin_get_by_interface(GST_BIN(pipeline), GST_TYPE_RTSPSRC); Thanks for your time Elio 2016-03-14 13:36 GMT+01:00 Sebastian Dröge <[hidden email]>: On Mo, 2016-03-14 at 12:33 +0100, elio francesconi wrote: _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On Mo, 2016-03-14 at 16:49 +0100, elio francesconi wrote:
> Hi Sebastian > thanks for your hint. > As you suggested I got the rtspBin element using: > GstElement * rtspBin = gst_bin_get_by_name(GST_BIN(pipeline), > "rtspsrc0"); > AFAIK the name is "rtspsrc0" and changes everytime I create a > pipeline, it impossible for me detect the name because the second > time the name is "rtspsrc1" the third "rtspsrc2"... > Which is the correct behaviour to detect the name? "rtspsrc name=source location=rtsp://.... ! ..." and then use "source" as the name. > Or.. Can I get the rtspBin using gst_bin_get_by_interface? > In this case I can find files to include to be defined > GST_TYPE_RTSPSRC (I'm using GStreamer library 1.6.1 under iOS) > > This is my code. > GstElement * rtspBin = gst_bin_get_by_interface(GST_BIN(pipeline), > GST_TYPE_RTSPSRC); You should get a linker error with that, GST_TYPE_RTSPSRC is not part of public headers or the libraries. Also it is not an interface type. -- Sebastian Dröge, Centricular Ltd · http://www.centricular.com _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel signature.asc (968 bytes) Download Attachment |
Free forum by Nabble | Edit this page |