VLC playing gstreamer flow

I am using gstreamer to generate a flow:
RPORT=11841
RCLIENT_IP=239.255.0.1

PORT=5000
CLIENT_IP=239.255.0.1

gst-launch-1.0 udpsrc multicast-group=${RCLIENT_IP} port=${RPORT} ! tsdemux name=demux demux. ! mpeg4videoparse ! omxmpeg4videodec ! nvvidconv ! ‘video/x-raw(memory:NVMM), format=(string)I420’ ! omxh265enc control-rate=2 bitrate=10000000 ! ‘video/x-h265, stream-format=(string)byte-stream’ ! h265parse ! rtph265pay mtu=1400 ! udpsink host=$CLIENT_IP port=${PORT} sync=false async=false

I start VLC and open the network stream “udp://@239.255.0.1:5000” and nothing plays. Can someone tell me what I am missing?

K-

Hi kunice, have you checked https://devtalk.nvidia.com/default/topic/1003598/ ?

Please also try test-launch.c @ gst-rtsp-server/test-launch.c at master · GStreamer/gst-rtsp-server · GitHub

Target
sudo apt-get install libgstrtspserver-1.0 libgstreamer1.0-dev
gcc test-launch.c -o test-launch $(pkg-config --cflags --libs gstreamer-1.0 gstreamer-rtsp-server-1.0)
./test-launch “videotestsrc ! omxh265enc ! rtph265pay name=pay0 pt=96”

Host
Open network stream rtsp://<TARGET_IP_ADDRESS>:8554/test via VLC

Thanks. The test-launch.c worked. Trouble is I need to send it all UDP (not RTSP). I am trying the other link and getting an error:
nvidia@tegra-ubuntu:~/scripts/works/live$ ./udp

(udp:5848): GLib-GObject-WARNING **: g_object_set_valist: object class ‘GstVideoTestSrc’ has no property named ‘source’
Inside NvxLiteH264DecoderLowLatencyInitNvxLiteH264DecoderLowLatencyInit set DPB and MjstreamingInside NvxLiteH265DecoderLowLatencyInitNvxLiteH265DecoderLowLatencyInit set DPB and MjstreamingFramerate set to : 60 at NvxVideoEncoderSetParameterNvMMLiteOpen : Block : BlockType = 4
===== MSENC =====
NvMMLiteBlockCreate : Block : BlockType = 4
===== MSENC blits (mode: 1) into tiled surfaces =====
^CSending EOS signal to shutdown pipeline cleanly
End of stream

… It would be nice if someone knew the ‘secret’ plugin that enables VLC to parse a gstreamer UDP flow…just saying.

Hi kunice, it is more like a problem in gstreamer frameworks. Please check if you can get help from http://gstreamer-devel.966125.n4.nabble.com/

Hi kunice,

Have you resolved this issue?
Any further assistance required?

Thanks

This is closed thanks.

Hi,

I am also trying to stream recorded .mkv video as a MPEG - TS with udp multicast IP.

Can someone help me?

I posted a topic. The link is here : [url]https://devtalk.nvidia.com/default/topic/1051080/jetson-tx2/gstreamer-mpeg-ts-udp-multicast-video-stream/post/5334523/#5334523[/url]

Hi DaneLLL,

Here, you mentioned how to use the test-launch.c server for the rtsp stream.

Is there a way where I can launch the ./test-launch and not be in the gst-rtsp-server directory? If I move the test-launch.c file to the home directory would that affect anything?

Also, I have this streaming code now using the test-launch.c

./test-launch "gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM), width=3280, height=1848, framerate=28/1, format=NV12'  ! nvvidconv left=200 right=3080 top=600 bottom=1200 !  'video/x-raw,width=2880, height=600, framerate=28/1, format=NV12, pixel-aspect-ratio=1/1' ! nvvidconv ! nvv4l2h264enc ! h264parse ! flvmux ! rtspsink location='rtsp://localhost:8554/live'"

I edited the code from this pipeline :

gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM), width=3280, height=1848, framerate=28/1, format=NV12'  ! nvvidconv left=200 right=3080 top=600 bottom=1200 !  'video/x-raw,width=2880, height=600, framerate=28/1, format=NV12, pixel-aspect-ratio=1/1' ! nvvidconv ! nvv4l2h264enc ! h264parse ! flvmux ! rtmpsink location='rtmp://localhost/live/'

It however does not work and I get this error when I try to use opencv to receive the stream :

./test-launch "gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM), width=3280, height=1848, framerate=28/1, format=NV12'  ! nvvidconv left=200 right=3080 top=600 bottom=1200 !  'video/x-raw,width=2880, height=600, framerate=28/1, format=NV12, pixel-aspect-ratio=1/1' ! nvvidconv ! nvv4l2h264enc ! h264parse ! flvmux ! rtspsink location='rtsp://localhost:8554/live'"
stream ready at rtsp://127.0.0.1:8554/test

(test-launch:8038): GStreamer-CRITICAL **: 21:34:17.698: gst_element_make_from_uri: assertion 'gst_uri_is_valid (uri)' failed

(test-launch:8038): GStreamer-CRITICAL **: 21:34:17.704: gst_element_make_from_uri: assertion 'gst_uri_is_valid (uri)' failed

(test-launch:8038): GStreamer-CRITICAL **: 21:34:17.754: gst_element_make_from_uri: assertion 'gst_uri_is_valid (uri)' failed

(test-launch:8038): GStreamer-CRITICAL **: 21:34:17.754: gst_element_make_from_uri: assertion 'gst_uri_is_valid (uri)' failed

It should end with rtph265pay(or rtph264pay)

"videotestsrc ! omxh265enc ! rtph265pay name=pay0 pt=96"

Suggest you verify the example first and then adapt to your usecase.

1 Like

I have tried test-launch application like you said but i got nothing when i trying to connect with ffplay or vlc. Any idea why? I am testing using ubuntu 18.04 x86-64 with deepstream installed 5.0.

./test-launch "videotestsrc ! omxh265enc ! rtph265pay name=pay0 pt=96"
stream ready at rtsp://127.0.0.1:8554/test

Hi,
Please utilize nvv4l2h264enc or nvv4l2h265enc. For your reference:

Hi @DaneLLL I used the rtsp test-launch and i am able to view in the stream on one vlc but when i try to view the stream from another vlc window it fails with this error:

** (test-launch:7901): WARNING **: 16:33:32.505: ignoring stream 0 without media type
Opening in BLOCKING MODE
NvMMLiteOpen : Block : BlockType = 4
===== NVMEDIA: NVENC =====
NvMMLiteBlockCreate : Block : BlockType = 4
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, execute:568 Failed to create CaptureSession

the command i am using to run the stream :

./test-launch “nvarguscamerasrc ! video/x-raw(memory:NVMM), format=NV12, width=1920, height=1080’ ! nvv4l2h264enc insert-sps-pps=true ! h264parse ! rtph264pay name=pay0 pt=96 config-interval=1”

Is it possible to view multiple instances ,of a single stream from csi camera, on remote VLC using the test-launch way ?

Hi,
It looks like the source cannot be launched successfully. You may run the pipeline:

gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM), format=NV12, width=1920, height=1080' ! nvoverlaysink

And check if you can see video preview.

it does not work for me :

root@ziomario-desktop:/home/ziomario/Desktop/Tools/gst-rtsp-server/examples# gcc test-launch.c -o test-launch
test-launch.c:20:10: fatal error: gst/gst.h: No such file or directory
#include <gst/gst.h>
^~~~~~~~~~~
compilation terminated.

root@ziomario-desktop:/home/ziomario/Desktop/Tools/gst-rtsp-server/examples# gcc test-launch.c -o test-launch $(pkg-config --cflags --libs gstreamer-1.0 gstreamer-rtsp-server-1.0)
test-launch.c: In function ‘main’:
test-launch.c:77:3: warning: implicit declaration of function ‘gst_rtsp_media_factory_set_enable_rtcp’; did you mean ‘gst_rtsp_media_factory_set_latency’? [-Wimplicit-function-declaration]
gst_rtsp_media_factory_set_enable_rtcp (factory, !disable_rtcp);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
gst_rtsp_media_factory_set_latency
/tmp/ccJPG5EO.o: In function main': test-launch.c:(.text+0x154): undefined reference to gst_rtsp_media_factory_set_enable_rtcp’
collect2: error: ld returned 1 exit status

2 Likes

I had the same issue. The repo a few versions newer than the apt installed package.
Checkout an earlier branch of the gst-rtsp-server repo, 1.18.5 worked for me.