rtspsrc cannot work with video file streaming

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view

rtspsrc cannot work with video file streaming

Tran Tu
Hi there,

I try to stream one mkv video file, which is recorded from camera via RTSP server.
But using gst-launch-1.0 only play 1 second and then:
- Got EOS from element "pipeline0"
Although the recorded video is 30s duration.

The same streaming can be work if I change the client by VLC.

Can anyone give me a hint whether I lacked of any configuration for the gst pipeline?

gst-launch-1.0 -v rtspsrc location=rtsps:// user-id=test user-pw=1234 ! decodebin ! fpsdisplaysink
Reply | Threaded
Open this post in threaded view

Re: rtspsrc cannot work with video file streaming

It works nicely at 1.10.3 if you have all the dependencies installed - particularly the srtp plugins in the rtspserver.
On OSX, this pipeline will play live audio and video that has been streamed with this server pipeline in the rtspserver using the test-video.c in the rtspserver examples with DEFINE TLS and DEFINE AUTH both set


v4l2src device=/dev/video2 ! video/x-h264,width=1280,height=720,framerate=20/1 ! h264parse ! rtph264pay pt=96 name=pay0  alsasrc device="plughw:C920_1,DEV=0" do-timestamp=true ! audio/x-raw,format=S16LE,rate=16000,depth=16,channels=1 ! queue ! audioresample ! audio/x-raw,format=S16LE,rate=8000,channels=1 ! faac ! rtpmp4apay pt=97 name=pay1


gst-launch-1.0 -e rtspsrc debug=1 location=rtsps://a.b.c.d:port/videoTX1 user-id=user user-pw=pass tls-validation-flags=generic-error protocols=tcp+tls name=dem1 dem1. ! decodebin ! autovideosink sync=true dem1. ! decodebin !  autoaudiosink sync=true

is an example - change a.b.c.d:port for wherever you have targetted your rtsps stream. Note that this does not test or check certificates - just allows encryption.