Streaming desktop with RTSP Gstreamer server

Back to my NX, it seems working . I used this pipeline for receiving on host:

gst-launch-1.0 rtspsrc location=rtsp://<Jetson_IP>:8554/test ! application/x-rtp, media=video, encoding-name=H264 ! rtph264depay ! h264parse ! avdec_h264 ! xvimagesink

like that?

server

./test-launch "ximagesrc use-damage=0 ! nvvidconv ! omxh264enc ! video/x-h264, profile=baseline ! h264parse ! video/x-h264, stream-format=byte-stream ! rtph264pay name=pay0 pt=96 "

client

 gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:8554/test ! application/x-rtp, media=video, encoding-name=H264 ! rtph264depay ! h264parse ! avdec_h264 ! xvimagesink

or like that:
server

gst-launch-1.0 -v ximagesrc use-damage=0 ! nvvidconv ! omxh264enc ! video/x-h264, profile=baseline ! h264parse ! video/x-h264, stream-format=byte-stream ! rtph264pay ! fakesink

client

gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:8554/test ! application/x-rtp, media=video, encoding-name=H264 ! rtph264depay ! h264parse ! avdec_h264 ! xvimagesink

Both or neither of the two?

Server requires test-launch. The gst-launch command was just for checking that the pipeline runs fine, because inside test-launch the error messages are filtered out.

test-launch "ximagesrc use-damage=0 ! nvvidconv ! omxh264enc ! video/x-h264, profile=baseline ! h264parse ! video/x-h264, stream-format=byte-stream ! rtph264pay name=pay0 pt=96 "

Client:

gst-launch-1.0 rtspsrc location=rtsp://<Jetson_IP>:8554/test ! application/x-rtp, media=video, encoding-name=H264 ! rtph264depay ! h264parse ! avdec_h264 ! xvimagesink

Note that if you run client on Jetson itself that the display will show a cascade of windows because ximagesrc takes the whole screen but xvimagesink displays in a smaller window.
Also note that the quality is not so good, you may want to try various options of the encoder, or try nvv4l2h264enc as well.

at AGX by some reason it throws

 gst-launch-1.0 rtspsrc location=rtsp://127.0.01:8554/test ! application/x-rtp, media=video, encoding-name=H264 ! rtph264depay ! h264parse ! avdec_h264 ! xvimagesink
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Progress: (open) Opening Stream
Progress: (connect) Connecting to rtsp://127.0.01:8554/test
ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Could not open resource for reading and writing.
Additional debug info:
gstrtspsrc.c(7469): gst_rtspsrc_retrieve_sdp (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0:
Failed to connect. (Generic error)
ERROR: pipeline doesn't want to preroll.
Setting pipeline to PAUSED ...
Setting pipeline to READY ...
Setting pipeline to NULL ...
Freeing pipeline ...

I shall try at NX

Might just be a typo in the IP address lacking a dot !

exactly!
good catch!
Thank you very much!

will it work with h.265?

./test-launch "ximagesrc use-damage=0 ! nvvidconv ! omxh265enc ! video/x-h265, profile=baseline ! h265parse ! video/x-h265, stream-format=byte-stream ! rtph265pay name=pay0 pt=96

Yes. You may get better quality.
Server:

./test-launch "ximagesrc use-damage=0 ! nvvidconv ! nvv4l2h265enc ! h265parse ! video/x-h265, stream-format=byte-stream ! rtph265pay name=pay0 pt=96 "

Client:

gst-launch-1.0 -v rtspsrc location=rtsp://<Jetson_IP>:8554/test ! application/x-rtp, media=video, encoding-name=H265 ! rtph265depay ! avdec_h265 ! xvimagesink

# local client can use jeston NVDEC
 gst-launch-1.0 -v rtspsrc location=rtsp://127.0.0.1:8554/test ! application/x-rtp, media=video, encoding-name=H265 ! rtph265depay ! nvv4l2decoder ! nvvidconv ! xvimagesink

Thx @Andrey1984

I was wondering if a source existed to capture the screen. That’s very useful to me.

add x2x and you will get a full remote desktop solution

@Andrey1984

Yeah. Was think of looking for some existing solution using GStreamer that could be modified to use Nvidia’s elements. Usually decode/encode bins can handle it automatically based on element rank but not always. From experience, encodebin is more difficult to use than decodebin. If you’re aware of anything close to what I am thinking of, lmk.

Streaming from headless nano Virtual Display - is it possible?
Steps to reproduce:

  1. put nx into multiuser mode & reboot
    sudo systemctl set-default multi-user.target
  2. ssh into nx & execute
sudo startx &
DISPLAY=:0 sudo xhost +
export DISPLAY=:0
 ./test-launch "ximagesrc use-damage=0 ! nvvidconv ! nvv4l2h265enc ! h265parse ! video/x-h265, stream-format=byte-stream ! rtph265pay name=pay0 pt=96 "

From another network device connect with

gst-launch-1.0 -v rtspsrc location=rtsp://<Jetson_IP>:8554/test ! application/x-rtp, media=video, encoding-name=H265 ! rtph265depay ! avdec_h265 ! xvimagesink

then adding
x2x mouse and keyboard from host [AGX] to NX virtual display:

ssh -X user@ipaddress 'x2x -west -to :0'

/usr/bin/xauth:  timeout in locking authority file /home/nvidia/.Xauthority
X11 connection rejected because of wrong authentication.
x2x - error: can not open display localhost:11.0

I understand that there might be required equivalent of the follwing command that seems not applicable to Jetson OS:

sudo nvidia-xconfig --allow-empty-initial-configuration --enable-all-gpus  --force-generate


probably somehow should be possible to execute an app to the display shown in the right?
Here trey reffer to using nvidia-xconfig, but the latter doesn’t seem presented into the system
https://docs.nvidia.com/jetson/l4t/index.html#page/Tegra%20Linux%20Driver%20Package%20Development%20Guide/window_system_x11.html

It seems I can change the underlying desktop resolution from the terminal with the command below

 xrandr --fb 1280x960

I’ve tried this pipeline and get an internal data stream error when the redistribute latency signal fires. The udpsrc rtspsrc uses internally throws a not negotiated error. The same thing happened when I tried to construct a pipeline which uses udpsrc and udpsink explicitly.

Any advice?

EDIT: I am using a jetson nano as the source and a surface pro running arch as the viewer of the rtp stream.

@blakat360 my re cords indicate that with VLC it was possible to use displayed jetson with

export DISPLAY=:0 && cd gst-rtsp-server-1.14.1/
cd examples
./test-launch "ximagesrc use-damage=0 ! nvvidconv ! nvv4l2h265enc ! h265parse ! video/x-h265, stream-format=byte-stream ! rtph265pay name=pay0 pt=96 "

if no hdmi connection present it won’t work unless specifically customized though

Running the above results in the following on the server:
Invalid MIT-MAGIC-COOKIE-1 keynvbuf_utils: Could not get EGL display connection
Invalid MIT-MAGIC-COOKIE-1 keyInvalid MIT-MAGIC-COOKIE-1 keyInvalid MIT-MAGIC-COOKIE-1 keyInvalid MIT-MAGIC-COOKIE-1 keyOpening in BLOCKING MODE
Opening in BLOCKING MODE
Invalid MIT-MAGIC-COOKIE-1 key

The client has the following output:
gst-launch-1.0 rtspsrc -v location=rtsp://192.168.1.184:8554/test ! application/x-rtp, media=video, encoding-name=H265 ! rtph265depay ! decodebin ! xvimagesink
Setting pipeline to PAUSED …
Pipeline is live and does not need PREROLL …
Progress: (open) Opening Stream
Pipeline is PREROLLED …
Prerolled, waiting for progress to finish…
Progress: (connect) Connecting to rtsp://192.168.1.184:8554/test
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0: Unhandled error
Additional debug info:
…/gst-plugins-good/gst/rtsp/gstrtspsrc.c(6696): gst_rtspsrc_send (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0:
Service Unavailable (503)
ERROR: pipeline doesn’t want to preroll.
Setting pipeline to NULL …
Freeing pipeline …

EDIT 1: When the display is set to :1 (which it defaults to when I have a screen plugged in) I get the following output on the server:
Opening in BLOCKING MODE
Opening in BLOCKING MODE
NvMMLiteOpen : Block : BlockType = 8
===== NVMEDIA: NVENC =====
NvMMLiteBlockCreate : Block : BlockType = 8
NVMEDIA: H265 : Profile : 1
NVMEDIA_ENC: bBlitMode is set to TRUE

and the client:
Setting pipeline to PAUSED …
Pipeline is live and does not need PREROLL …
Progress: (open) Opening Stream
Pipeline is PREROLLED …
Prerolled, waiting for progress to finish…
Progress: (connect) Connecting to rtsp://192.168.1.184:8554/test
Progress: (open) Retrieving server options
Progress: (open) Retrieving media info
Progress: (request) SETUP stream 0
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager: latency = 2000
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager: ntp-sync = false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager: rfc7273-sync = false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager: ntp-time-source = ntp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager: drop-on-latency = false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager: max-rtcp-rtp-time-diff = 1000
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager: max-ts-offset-adjustment = 0
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager: buffer-mode = slave
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc0: timeout = 5000000000
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc0: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc1: caps = application/x-rtcp
Progress: (open) Opened Stream
Setting pipeline to PLAYING …
New clock: GstSystemClock
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager: buffer-mode = slave
Progress: (request) Sending PLAY request
Progress: (request) Sending PLAY request
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc0: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
Progress: (request) Sent PLAY request
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc1.GstPad:src: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc1.GstPad:src: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager.GstGhostPad:recv_rtp_sink_0.GstProxyPad:proxypad1: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager.GstGhostPad:recv_rtp_sink_0.GstProxyPad:proxypad1: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpSession:rtpsession0.GstPad:sync_src: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpSsrcDemux:rtpssrcdemux0.GstPad:rtcp_sink: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpSsrcDemux:rtpssrcdemux0.GstPad:rtcp_sink: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpSession:rtpsession0.GstPad:recv_rtcp_sink: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager.GstGhostPad:recv_rtcp_sink_0: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpStorage:rtpstorage0.GstPad:src: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpSsrcDemux:rtpssrcdemux0.GstPad:sink: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpStorage:rtpstorage0.GstPad:sink: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpSession:rtpsession0.GstPad:recv_rtp_sink: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager.GstGhostPad:recv_rtp_sink_0: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc0: timeout = 0
Redistribute latency…
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: latency = 2000
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: drop-on-latency = false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: do-lost = false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: mode = slave
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: do-retransmission = false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: max-rtcp-rtp-time-diff = 1000
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: max-dropout-time = 60000
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: max-misorder-time = 2000
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: rfc7273-sync = false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0: max-ts-offset-adjustment = 0
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0.GstPad:sink: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpJitterBuffer:rtpjitterbuffer0.GstPad:src: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpPtDemux:rtpptdemux0.GstPad:sink: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstCapsFilter:capsfilter1: caps = application/x-rtp, media=(string)video, encoding-name=(string)H265
/GstPipeline:pipeline0/GstCapsFilter:capsfilter1.GstPad:src: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRtpH265Depay:rtph265depay0.GstPad:src: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01420101014000000300000300f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90
/GstPipeline:pipeline0/GstDecodeBin:decodebin0.GstGhostPad:sink.GstProxyPad:proxypad0: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01420101014000000300000300f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstTypeFindElement:typefind.GstPad:src: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01420101014000000300000300f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstH265Parse:h265parse0.GstPad:src: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01014000000000000000000078f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90, width=(int)1920, height=(int)1080, chroma-format=(string)4:2:0, bit-depth-luma=(uint)8, bit-depth-chroma=(uint)8, parsed=(boolean)true, profile=(string)main, tier=(string)main, level=(string)4
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/avdec_h265:avdec_h265-0.GstPad:sink: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01014000000000000000000078f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90, width=(int)1920, height=(int)1080, chroma-format=(string)4:2:0, bit-depth-luma=(uint)8, bit-depth-chroma=(uint)8, parsed=(boolean)true, profile=(string)main, tier=(string)main, level=(string)4
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstCapsFilter:capsfilter2.GstPad:src: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01014000000000000000000078f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90, width=(int)1920, height=(int)1080, chroma-format=(string)4:2:0, bit-depth-luma=(uint)8, bit-depth-chroma=(uint)8, parsed=(boolean)true, profile=(string)main, tier=(string)main, level=(string)4
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstCapsFilter:capsfilter2.GstPad:sink: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01014000000000000000000078f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90, width=(int)1920, height=(int)1080, chroma-format=(string)4:2:0, bit-depth-luma=(uint)8, bit-depth-chroma=(uint)8, parsed=(boolean)true, profile=(string)main, tier=(string)main, level=(string)4
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstH265Parse:h265parse0.GstPad:sink: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01420101014000000300000300f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstH265Parse:h265parse0.GstPad:src: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01014000000000000000000078f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90, width=(int)1920, height=(int)1080, chroma-format=(string)4:2:0, bit-depth-luma=(uint)8, bit-depth-chroma=(uint)8, parsed=(boolean)true, profile=(string)main, tier=(string)main, level=(string)4
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstCapsFilter:capsfilter2.GstPad:sink: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01014000000000000000000078f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90, width=(int)1920, height=(int)1080, chroma-format=(string)4:2:0, bit-depth-luma=(uint)8, bit-depth-chroma=(uint)8, parsed=(boolean)true, profile=(string)main, tier=(string)main, level=(string)4
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstTypeFindElement:typefind.GstPad:sink: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01420101014000000300000300f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90
/GstPipeline:pipeline0/GstDecodeBin:decodebin0.GstGhostPad:sink: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01420101014000000300000300f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90
/GstPipeline:pipeline0/GstRtpH265Depay:rtph265depay0.GstPad:sink: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstCapsFilter:capsfilter1.GstPad:sink: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0.GstGhostPad:recv_rtp_src_0_3102690005_96.GstProxyPad:proxypad5: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager.GstGhostPad:recv_rtp_src_0_3102690005_96.GstProxyPad:proxypad4: caps = application/x-rtp, media=(string)video, payload=(int)96, clock-rate=(int)90000, encoding-name=(string)H265, sprop-vps=(string)QAEMAf//AUAAAAMAAAMAAAMAAAMAeKwJ, sprop-sps=(string)QgEBAUAAAAMAAAMAAAMAAAMAeKADwIARB8uWt5CERLgg, sprop-pps=(string)“RAHAc8DMkA==”, a-tool=(string)GStreamer, a-type=(string)broadcast, a-framerate=(string)25, a-ts-refclk=(string)local, a-mediaclk=(string)sender, ssrc=(uint)3102690005, clock-base=(uint)3499200527, seqnum-base=(uint)20792, npt-start=(guint64)0, play-speed=(double)1, play-scale=(double)1, onvif-mode=(boolean)false
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstH265Parse:h265parse0.GstPad:src: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01014000000000000000000078f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90, width=(int)1920, height=(int)1080, chroma-format=(string)4:2:0, bit-depth-luma=(uint)8, bit-depth-chroma=(uint)8, parsed=(boolean)true, profile=(string)main, tier=(string)main, level=(string)4
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/GstCapsFilter:capsfilter2.GstPad:sink: caps = video/x-h265, stream-format=(string)hvc1, alignment=(string)au, codec_data=(buffer)01014000000000000000000078f000fcfdf8f800000f03200001001840010c01ffff01400000030000030000030000030078ac09210001002142010101400000030000030000030000030078a003c0801107cb96b7908444b82022000100074401c073c0cc90, width=(int)1920, height=(int)1080, chroma-format=(string)4:2:0, bit-depth-luma=(uint)8, bit-depth-chroma=(uint)8, parsed=(boolean)true, profile=(string)main, tier=(string)main, level=(string)4
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpSession:rtpsession0: stats = application/x-rtp-session-stats, rtx-drop-count=(uint)0, sent-nack-count=(uint)0, recv-nack-count=(uint)0, source-stats=(GValueArray)< “application/x-rtp-source-stats,\ ssrc=(uint)3102690005,\ internal=(boolean)false,\ validated=(boolean)true,\ received-bye=(boolean)false,\ is-csrc=(boolean)false,\ is-sender=(boolean)true,\ seqnum-base=(int)-1,\ clock-rate=(int)90000,\ rtp-from=(string)192.168.1.184:33478,\ octets-sent=(guint64)0,\ packets-sent=(guint64)0,\ octets-received=(guint64)817365,\ packets-received=(guint64)614,\ bytes-received=(guint64)841925,\ bitrate=(guint64)3307743,\ packets-lost=(int)-1,\ jitter=(uint)149,\ sent-pli-count=(uint)0,\ recv-pli-count=(uint)0,\ sent-fir-count=(uint)0,\ recv-fir-count=(uint)0,\ sent-nack-count=(uint)0,\ recv-nack-count=(uint)0,\ recv-packet-rate=(uint)3911,\ have-sr=(boolean)false,\ sr-ntptime=(guint64)0,\ sr-rtptime=(uint)0,\ sr-octet-count=(uint)0,\ sr-packet-count=(uint)0,\ sent-rb=(boolean)true,\ sent-rb-fractionlost=(uint)0,\ sent-rb-packetslost=(int)-1,\ sent-rb-exthighestseq=(uint)21406,\ sent-rb-jitter=(uint)149,\ sent-rb-lsr=(uint)0,\ sent-rb-dlsr=(uint)0,\ have-rb=(boolean)false,\ rb-fractionlost=(uint)0,\ rb-packetslost=(int)0,\ rb-exthighestseq=(uint)0,\ rb-jitter=(uint)0,\ rb-lsr=(uint)0,\ rb-dlsr=(uint)0,\ rb-round-trip=(uint)0;”, “application/x-rtp-source-stats,\ ssrc=(uint)947265870,\ internal=(boolean)true,\ validated=(boolean)true,\ received-bye=(boolean)false,\ is-csrc=(boolean)false,\ is-sender=(boolean)false,\ seqnum-base=(int)-1,\ clock-rate=(int)-1,\ octets-sent=(guint64)0,\ packets-sent=(guint64)0,\ octets-received=(guint64)0,\ packets-received=(guint64)0,\ bytes-received=(guint64)0,\ bitrate=(guint64)0,\ packets-lost=(int)0,\ jitter=(uint)0,\ sent-pli-count=(uint)0,\ recv-pli-count=(uint)0,\ sent-fir-count=(uint)0,\ recv-fir-count=(uint)0,\ sent-nack-count=(uint)0,\ recv-nack-count=(uint)0,\ recv-packet-rate=(uint)0,\ have-sr=(boolean)false,\ sr-ntptime=(guint64)0,\ sr-rtptime=(uint)0,\ sr-octet-count=(uint)0,\ sr-packet-count=(uint)0;” >, rtx-count=(uint)0, recv-rtx-req-count=(uint)0, sent-rtx-req-count=(uint)0;
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager/GstRtpSession:rtpsession0.GstPad:send_rtcp_src: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager.GstGhostPad:send_rtcp_src_0: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSink:udpsink1.GstPad:sink: caps = application/x-rtcp
/GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstRtpBin:manager.GstGhostPad:send_rtcp_src_0.GstProxyPad:proxypad3: caps = application/x-rtcp
/GstPipeline:pipeline0/GstDecodeBin:decodebin0/avdec_h265:avdec_h265-0.GstPad:src: caps = video/x-raw, format=(string)I420, width=(int)1920, height=(int)1080, interlace-mode=(string)progressive, pixel-aspect-ratio=(fraction)1/1, chroma-site=(string)mpeg2, colorimetry=(string)2:0:0:0, framerate=(fraction)25/1
Redistribute latency…
ERROR: from element /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc0: Internal data stream error.
Additional debug info:
…/gstreamer/libs/gst/base/gstbasesrc.c(3127): gst_base_src_loop (): /GstPipeline:pipeline0/GstRTSPSrc:rtspsrc0/GstUDPSrc:udpsrc0:
streaming stopped, reason not-negotiated (-4)
Execution ended after 0:00:02.077542856
Setting pipeline to NULL …
Freeing pipeline …

EDIT2: The stream can be played through VLC like this. Why won’t the gstreamer client pick it up?

this specifically line was tested/ confirmed for VLC specifically
It seems it worked at your side within the confirmed scope

The problem may be that your client pipeline uses decodebin, that would pick up nvv4l2decoder for H265 decoding on Jetson, but this decoder outputs into NVMM memory that cannot be handled by xvimagesink.
You may try adding nvvidconv between decodebin and xvimagesink.

my records indicate that the following pipeline [ credits to @Honey_Patouceul ] worked at some point of time

./test-launch "ximagesrc use-damage=0 ! nvvidconv ! omxh264enc ! video/x-h264, profile=baseline ! h264parse ! video/x-h264, stream-format=byte-stream ! rtph264pay name=pay0 pt=96 "

client side


gst-launch-1.0 rtspsrc location=rtsp://127.0.0.1:8554/test ! application/x-rtp, media=video, encoding-name=H264 ! rtph264depay ! h264parse ! avdec_h264 ! xvimagesink

However, tests were conducted both server/client on the same AGX