The device I use is the jetson nano. Mp4 videos can be read normally when using Gstreamer but there is no window display. And other methods can also read the video stream normally. When I use playbin in Gstreamer, the program keeps getting stuck in the Redistribute lattency step. I also tried using the sudo apt-get remove gstreamer1.0-plugins-ugly command, but it didn’t work. How can I read rtsp video streams properly through Gstreamer?
Hi,
Please refer to the posts to make sure the URI is read correctly:
Deepstream 5.1 Test 3 RTSP Camera INPUT - #3 by DaneLLL
Python Bindings for DeepStream not working with RTSP stream - #8 by DaneLLL
I tried the method mentioned in the post, but it didn’t work, and still stuck in the ‘Redistribute latency’ as before.
Hi,
Please try software decoder:
rtspsrc ! rtph264depay ! h264parse ! avdec_h264 ! videoconvert ! xvimagesink
Hi, I tried your method but it still didn’t work.Below is my log.
log.txt (4.2 KB)
Hi,
You miss a !
in the command:
gst-launch-1.0 rtspsrc uri="rtsp://admin:wzu123456@192.168.1.64:554" rtph264depay ! h264parse ! avdec_h264 ! videoconvert ! xvimagesink
Please try
gst-launch-1.0 rtspsrc uri="rtsp://admin:wzu123456@192.168.1.64:554" ! rtph264depay ! h264parse ! avdec_h264 ! videoconvert ! xvimagesink
And can try the commands:
gst-launch-1.0 rtspsrc uri="rtsp://admin:wzu123456@192.168.1.64:554" ! fakesink
gst-launch-1.0 rtspsrc uri="rtsp://admin:wzu123456@192.168.1.64:554" ! rtph264depay ! h264parse ! avdec_h264 ! fakesink
There have been other mistakes.
log1.txt (5.1 KB)
Hi,
The URI should be invalid if none of the commands works. Would suggest check with camera vendor to obtain a valid URI first.
But I can successfully open the same URI in VLC, is Gstreamer has any special requirements for URIs?
What outputs give these commands ?
gst-discoverer-1.0 -v "rtspt://admin:wzu123456@192.168.1.64:554/h264/ch1/main/av_stream"
gst-play-1.0 -v "rtspt://admin:wzu123456@192.168.1.64:554/h264/ch1/main/av_stream"
gst-launch-1.0 -v uridecodebin uri="rtspt://admin:wzu123456@192.168.1.64:554/h264/ch1/main/av_stream" ! fakesink
gst-launch-1.0 -v uridecodebin uri="rtspt://admin:wzu123456@192.168.1.64:554/h264/ch1/main/av_stream" ! autovideosink filter-caps="video/x-raw(memory:NVMM)"
Here is the output of the command.
log2.txt (267.8 KB)
I found out that the camera was encoded in H.265(oddly enough, H.264 in the rtsp was misleading), but when I changed the camera to H.264, it didn’t show up. log as follows.
log3.txt (2.7 KB)
I’ve solved the problem. A delay of less than 1 second can be achieved with the following instructions:
gst-launch-1.0 rtspsrc location=“rtspt://admin:wzu123456@192.168.1.64:554/h264/ch1/main/av_stream” latency=0 ! rtph264depay ! h264parse ! omxh264dec ! nvvidconv ! xvimagesink sync=false
Finally, thank you very much for your help!!!
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.