Hi,
I am using sricam SP019 IP(Wireless) camera.
I have been able to find the RTSP URL for my camera: ("rtsp://IP_ADDRESS:554/onvif1").
However, I am unable to open the RTSP stream using openCV VideoCapture interface.
Already tried ( and didn't help much )-
However, I still keep getting the error shown: GLib-GObject-CRITICAL **: g_object_set: assertion 'G_IS_OBJECT (object)' failed
My question:
It would be extremely helpful if someone could give a hint as to what's causing the error.
Thanks!
_______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On 01/22/2018 04:36 AM, Jajoo, Malhar
wrote:
1) Try playing the RTSP stream in something like VLC (videolan.org) to make sure the camera is working
2) Try using gst-launch-1.0 at the command line to build a pipeline that plays your camera stream with just GStreamer; this would isolate it from any OpenCV issues (for which you may not find much help here).
something like:
$ gst-launch-1.0 -v rtspsrc location=<a class="moz-txt-link-freetext" href="rtsp://IP_ADDRESS:554/onvif1">rtsp://IP_ADDRESS:554/onvif1 ! rtph264depay ! avdec_h264 ! videoconvert ! xvimagesink
there are also more automatic/portable ways to do that with playbin, e.g.:
gst-launch-1.0 -v playbin uri=<a class="moz-txt-link-freetext" href="rtsp://IP_ADDRESS:554/onvif1">rtsp://IP_ADDRESS:554/onvif1
Cheers,
Mark. _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Hi Mark,
Thanks a lot for your suggestion. I have been able to play the RTSP stream in VLC media player.
the central focus of my project :( . Any help will be greatly appreciated.
Best,
Malhar
From: gstreamer-devel <[hidden email]> on behalf of Mark Howell <[hidden email]>
Sent: Monday, January 22, 2018 8:01:56 PM To: [hidden email] Subject: Re: Critical Error reading RTSP stream from IP cameras On 01/22/2018 04:36 AM, Jajoo, Malhar wrote:
1) Try playing the RTSP stream in something like VLC (videolan.org) to make sure the camera is working
2) Try using gst-launch-1.0 at the command line to build a pipeline that plays your camera stream with just GStreamer; this would isolate it from any OpenCV issues (for which you may not find much help here).
something like:
$ gst-launch-1.0 -v rtspsrc location=rtsp://IP_ADDRESS:554/onvif1 ! rtph264depay ! avdec_h264 ! videoconvert ! xvimagesink
there are also more automatic/portable ways to do that with playbin, e.g.:
gst-launch-1.0 -v playbin uri=rtsp://IP_ADDRESS:554/onvif1
Cheers,
Mark. _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On 01/22/2018 01:05 PM, Jajoo, Malhar
wrote:
Sounds like maybe your GStreamer installation does not have all these elements installed. That's not unusual, it's often broken up into multiple packages depending on the platform. I didn't catch whether you were linux, mac, windows etc. h264parse, for example, is in gst-plugins-bad, go see if such a package is installed on your system, if not, find it. You can look for information on individual elements (if they are present) with, for example: $ gst-inspect-1.0 h264parse Or list them all with: $ gst-inspect-1.0 Or look for stuff mentioning h.264 with, e.g.: $ gst-inspect-1.0 -a | grep h264 Last, come back with more specific error messages rather than just "some errors" Cheers, Mark. _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
In reply to this post by Mark Howell
Adding to Mark's answer.
Check whether your Gstreamer installation has gst-libav installed or not? In windows it is generally installed in standard installation. In linux you have to do it separately. After that check the following gst-inspect-1.0 avdec_h264 If this element details are available, you can use following command straightaway in your OpenCV implementation. cap = cv::VideoCapture("rtspsrc location=rtsp://IP_ADDRESS:554/onvif1 latency=## ! rtph264depay ! avdec_h264 ! videoconvert ! appsink") This will directly allow you to use cap.read(). I have tested it in Python. I don't see any reason for this to not work in C++. Cheers, Sachchit -- Sent from: http://gstreamer-devel.966125.n4.nabble.com/ _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Free forum by Nabble | Edit this page |