Stream H264 encoded by Jetson Nano by RTP and decode using CPU/GPU

omer.tal jacklawi at gmail.com
Sun Nov 1 14:28:31 UTC 2020


Hey all,

I'm fairly new to gstreamer, so I'm sorry if this is a newbie question...

I have an NVIDIA Jetson Nano device, which I use in order to stream H264 to
a computer within my subnet using RTP.
I'm having some difficulties performing this task.

The pipeline I use for the server is:
/gst-launch-1.0 -v -e v4l2src ! 'video/x-raw,framerate=30/1' ! nvvidconv !
'video/x-raw(memory:NVMM)' ! nvv4l2h264enc birate=1000000 iframeinterval=100
! rtph264pay ! udpsink host=192.168.1.181 port=5010/

The receiver:
/GST_DEBUG=4 gst-launch-1.0 -e -v udpsrc port=5010 caps=application/x-rtp !
queue ! rtph264depay ! h264parse ! decodebin ! autovideosink/

The main issue is that there is not much movement in front of the camera,
the image on the receiver end is shown corrupted.
I used GST_DEBUG=4 and found that when receiving a corrupted sequence like
that, I'm getting the following message:
/0:00:05.821975090 10098 0x562bb62b5050 INFO                   libav :0::
Got unexpected packet after EOF
0:00:05.822990045 10098 0x562bb62b5050 INFO                   libav :0::
Reinit /

Also I've noticed that when I play with the /bitrate/ and /iframeinterval/
parameters - this error behaves differently.
For example: If I set the bitrate to 8000000 (which is used in all NVIDIA's
examples) nothing is displayed.
When I'm setting it to 4000000, I see image but it is completely corrupted
(only see edges of objects).
When settings it to a really low value, it looks fine and no corruptions at
all.
Also, when setting the iframeinterval to 5 and lower, I also don't get any
corrupted frames.

The second thing I'm wondering about it, when I try to replace my CPU
decoder (avdec_h264) with nvdec I get many dropped frames:

/0:00:14.195356201 22641 0x55c1dcfdb6d0 WARN               h264parse
gsth264parse.c:1237:gst_h264_parse_handle_frame:<h264parse0> broken/invalid
nal Type: 1 Slice, Size: 1667 will be dropped
0:00:14.226333599 22641 0x55c1dcfdb6d0 WARN               h264parse
gsth264parse.c:1237:gst_h264_parse_handle_frame:<h264parse0> broken/invalid
nal Type: 1 Slice, Size: 12719 will be dropped
.../

I would love to give more information in case I missed something.

Thanks in advance to anyone who can assist.

:)



--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/


More information about the gstreamer-devel mailing list