TX2 H264 RTSP Stream decoding issues

Hi nikosR,
Can you try the following pipelines:

rtspsrc location="rtsp://my_ip_here/test" ! rtph264depay ! h264parse ! omxh264dec ! nvoverlaysink sync=false
rtspsrc location="rtsp://my_ip_here/test" ! rtph264depay ! h264parse ! omxh264dec ! fakesink
rtspsrc location="rtsp://my_ip_here/test" ! rtph264depay ! h264parse ! omxh264dec ! fakesink sync=false

You mention it only happens in variable frame rate. Probably something wrong in sync mechanism.

Hi DaneLLL,

#1 No CPU increase, however was not very stable and after 20 or 30 minutes it would freeze preview.
1.rtspsrc location=“rtsp://my_ip_here/test” ! rtph264depay ! h264parse ! omxh264dec ! nvoverlaysink sync=false

#2 CPU increase issue.
2.rtspsrc location=“rtsp://my_ip_here/test” ! rtph264depay ! h264parse ! omxh264dec ! fakesink

#3 Similar to #1
3.rtspsrc location=“rtsp://my_ip_here/test” ! rtph264depay ! h264parse ! omxh264dec ! fakesink sync=false

In conclusion, the software decoder is very stable maintaining the pipeline for many days but too slow for application. Have not found yet any stable hardware decoder pipeline.

Hi nikosR,
Please share a transport stream by running:

rtspsrc location="rtsp://my_ip_here/test" ! rtph264depay ! h264parse ! mpegtsmux ! filesink location=a.ts

We don’t have stream with variable frame rate. Please help to generate one. 6 min should be enough since you have mentioned CPU usage increases after two minutes.

Hi DaneLLL,

Just reset the camera and captured a few minutes of the RTSP stream using the command you suggested above. Not sure if this stream is still VFR after the reset but still getting the same issues when we try to stream and use the omxh264dec decoder.

https://www.dropbox.com/s/mym4spn7238604u/a.ts?dl=0

JFYI: on Jetson I was getting WARNING: erroneous pipeline: no element “mpegtsmux” so I captured on desktop instead.

Hi nikosR,

We run the “a.ts” with below pipeline:

gst-launch-1.0 filesrc location= a.ts ! tsdemux ! h264parse ! omxh264dec ! nvoverlaysink

We playing video 10"35 and check tegrastats usage result looks normally, it doesn’t gets high.
Attached “tegrastats.txt” for you reference.
tegrastats.txt (72.3 KB)

Could you provide the content of the file “test-launch” , please?:

cat test-launch

Upd:
It appears that it refers to https://devtalk.nvidia.com/default/topic/968782/jetson-tk1/making-a-720p-live-video-monitoring/post/4994290/#4994290
and hence to the gstreamer-1.8.0.tar.xz
What I am trying to do is to get onboard ov5693 sensor casting the video over the network.
Any advice appreciated.
Upd:
perhaps the file to download is
https://gstreamer.freedesktop.org/src/gst-plugins-base/gst-plugins-base-1.8.3.tar.xz
Upd it appears to me that I shall get three file with 1.8.3 versions instead of

On the other hand the file gst-rtsp-server-1.8.3.tar.xz may be redundant.
However, trying with https://gstreamer.freedesktop.org/src/gst-rtsp-server/gst-rtsp-server-1.8.3.tar.xz

wget https://gstreamer.freedesktop.org/src/gst-rtsp-server/gst-rtsp-server-1.8.3.tar.xz
tar -xvf gst-rtsp-server-1.8.3.tar.xz
cd gst-rtsp-server-1.8.3
./configure --libdir=/usr/lib/arm-linux-gnueabihf/
make
cd examples
 ./test-launch "nvcamerasrc ! video/x-raw(memory:NVMM),width=1920,height=1080,format=NV12,frametate=30/1 ! omxh264enc bitrate=10000000 ! rtph264pay name=pay0 pt=96"
stream ready at rtsp://127.0.0.1:8554/test

Now I am trying to get the stream with

$ gst-launch-1.0 rtspsrc location="rtsp://127.0.0.1:8554/test" ! rtph264depay ! h264parse ! omxh264dec ! nvoverlaysink

But it throws 503 error

gst-launch-1.0 rtspsrc location="rtsp://127.0.0.1:8554/test" ! rtph264depay ! h264parse ! omxh264dec ! nvoverlaysink
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://127.0.0.1:8554/test
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Could not read from resource.
Additional debug info:
gstrtspsrc.c(5670): gst_rtspsrc_send (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0:
Got error response: 503 (Service Unavailable).
ERROR: pipeline doesn't want to preroll.
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

As I can see, when I am trying to read the stream the terminal that has the server returns the line:

Socket read error. Camera Daemon stopped functioning.....
gst_nvcamera_open() failed ret=0

However after a reboot I got slightly different picture.
server terminal:

./test-launch "nvcamerasrc ! video/x-raw(memory:NVMM),width=1920,height=1080,format=NV12,frametate=30/1 ! omxh264enc bitrate=10000000 ! rtph264pay name=pay0 pt=96"
stream ready at rtsp://127.0.0.1:8554/test

Available Sensor modes : 
2592 x 1944 FR=30.000000 CF=0x1109208a10 SensorModeType=4 CSIPixelBitDepth=10 DynPixelBitDepth=10
2592 x 1458 FR=30.000000 CF=0x1109208a10 SensorModeType=4 CSIPixelBitDepth=10 DynPixelBitDepth=10
1280 x 720 FR=120.000000 CF=0x1109208a10 SensorModeType=4 CSIPixelBitDepth=10 DynPixelBitDepth=10

NvCameraSrc: Trying To Set Default Camera Resolution. Selected sensorModeIndex = 1 WxH = 2592x1458 FrameRate = 30.000000 ...

Framerate set to : 30 at NvxVideoEncoderSetParameterFramerate set to : 30 at NvxVideoEncoderSetParameterFramerate set to : 30 at NvxVideoEncoderSetParameterFramerate set to : 30 at NvxVideoEncoderSetParameterFramerate set to : 30 at NvxVideoEncoderSetParameterFramerate set to : 30 at NvxVideoEncoderSetParameter

client terminal

/gst-rtsp-server-1.8.3/examples$ gst-launch-1.0 rtspsrc location="rtsp://127.0.0.1:8554/test" ! rtph264depay ! h264parse ! omxh264dec ! nvoverlaysink
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://127.0.0.1:8554/test
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Could not read from resource.
Additional debug info:
gstrtspsrc.c(5670): gst_rtspsrc_send (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0:
Got error response: 503 (Service Unavailable).
ERROR: pipeline doesn't want to preroll.
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

shall I install [or rather reinstall] the other packages : gstreamer-1.8.0.tar.xz, gst-plugins-base-1.8.0.tar.xz[or newer equivalents] , presuming I am running the client and the streaming server at flashed with Jetpack 3.2 devboard?
Upd: solution has been distinguished as the line below

./test-launch "( nvcamerasrc sensor-id=0 ! video/x-raw(memory:NVMM), width=1920, height=1080, framerate=30/1, format=I420 ! nvvidconv flip-method=4 ! video/x-raw, width=720, height=480, framerate=30/1, format=I420 ! timeoverlay ! omxh265enc ! rtph265pay name=pay0 pt=96 )"

Upd:

./test-launch "( nvcamerasrc sensor-id=0 ! video/x-raw(memory:NVMM), width=1920, height=1080, framerate=30/1, format=NV12 ! omxh265enc ! rtph265pay name=pay0 pt=96 )"

Now with the line below it seems to connect:

gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:8554/test latency=1000 ! rtph265depay ! fakesink

But it doesn’t throw out the video output window.
Update: The issue seems resolved as the code below throws out an output in a pop up window with video streaming.

gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:8554/test  ! 'application/x-rtp, media=(string)video' ! decodebin ! videoconvert ! ximagesink