gst-launch-1.0 uridecodebin uri="rtsp://stream" ! autovideosink
Progress: (request) Sending PLAY request
Progress: (request) Sending PLAY request
Progress: (request) Sent PLAY request
WARNING: from element /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source: Could not read from resource.
Additional debug info:
gstrtspsrc.c(5768): gst_rtspsrc_reconnect (): /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source:
Could not receive any UDP packets for 5.0000 seconds, maybe your firewall is blocking it. Retrying using a tcp connection.
WARNING: from element /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0: Delayed linking failed.
Additional debug info:
./grammar.y(506): gst_parse_no_more_pads (): /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0:
failed delayed linking some pad of GstURIDecodeBin named uridecodebin0 to some pad of GstAutoVideoSink named autovideosink0
terminal gets frozen after running this command.
But if I run
gst-launch-1.0 rtspsrc location="rtsp://stream" ! queue ! rtph264depay ! h264parse ! avdec_h264 ! videoconvert ! videoscale ! autovideosink
or
gst-launch-1.0 playbin uri="rtsp://stream"
both work fine.
And even first command works fine on my Windows machine. Problem is present on remote Ubuntu server. I have a suspicion that firewall could be involved. But I dont understand why playbin or rtspsrc could get through, and uridecodebin frozes for like 10 minutes and then crashes with:
ERROR: from element /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source: Could not read from resource.
Additional debug info:
gstrtspsrc.c(5559): gst_rtspsrc_loop_interleaved (): /GstPipeline:pipeline0/GstURIDecodeBin:uridecodebin0/GstRTSPSrc:source:
Could not receive message. (Parse error)
And I want to use uridecodebin
because I want it to be able to handle all kinds of different uri(not only rtsp), and need to connect it to app_sink
. Dont know if there is any other way to do it.
I think it is a bug, because after upgrading from 1.16.2 to 1.20.1 problem is gone. That's a problem because on Ubuntu 20.04 only 1.16.2 is present via distro package and there is no convenient way to update version without building from sources which has it problems.