Stream CSI camera over network

Dear Gstreamer and encoding Experts,

I am struggling with the streaming of a CSI based IMX678 camera over the network. It works with both following commands for the local preview :

  • 4K :
    DISPLAY=:0 gst-launch-1.0 nvarguscamerasrc ! "video/x-raw(memory:NVMM), width=(int)3840, height=(int)2160format=(string)NV12, framerate=(fraction)30/1" ! nvvidconv ! xvimagesink sync=false

-1080p :
DISPLAY=:0 gst-launch-1.0 nvarguscamerasrc sensor-mode=2 ! "video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080,format=(string)NV12, framerate=(fraction)30/1" ! nvvidconv ! xvimagesink sync=false

But when I tried streaming over the network with H264 encoding :

  • 4K :
    gst-launch-1.0 nvarguscamerasrc ! 'video/x-raw(memory:NVMM), width=(int)3840, height=(int)2160, format=(string)NV12, framerate=(fraction)30/1' ! nvv4l2h264enc ! h264parse ! rtph264pay name=pay0 pt=96 ! udpsink host=192.168.1.97 port=5000

  • 1080p :
    gst-launch-1.0 nvarguscamerasrc sensor-mode=2 ! 'video/x-raw(memory:NVMM), width=(int)1920, height=(int)1080, format=(string)NV12, framerate=(fraction)30/1' ! nvv4l2h264enc ! h264parse ! rtph264pay name=pay0 pt=96 ! udpsink host=192.168.1.97 port=5000

I got following error :

Setting pipeline to PAUSED ...
Opening in BLOCKING MODE 
Pipeline is live and does not need PREROLL ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Redistribute latency...
NvMMLiteOpen : Block : BlockType = 4 
===== NvVideo: NVENC =====
NvMMLiteBlockCreate : Block : BlockType = 4 
GST_ARGUS: Creating output stream
CONSUMER: Waiting until producer is connected...
GST_ARGUS: Available Sensor modes :
GST_ARGUS: 3856 x 2180 FR = 29,999999 fps Duration = 33333334 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 27000, max 660000000;

GST_ARGUS: 2608 x 1964 FR = 33,000000 fps Duration = 30303030 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 27000, max 660000000;

GST_ARGUS: 1920 x 1080 FR = 59,000002 fps Duration = 16949152 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 27000, max 660000000;

GST_ARGUS: 1928 x 1090 FR = 29,999999 fps Duration = 33333334 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 27000, max 660000000;

GST_ARGUS: 3856 x 2180 FR = 29,999999 fps Duration = 33333334 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 27000, max 660000000;

GST_ARGUS: 2608 x 1964 FR = 33,000000 fps Duration = 30303030 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 27000, max 660000000;

GST_ARGUS: 1920 x 1080 FR = 59,000002 fps Duration = 16949152 ; Analog Gain range min 1,000000, max 3981,070801; Exposure Range min 27000, max 660000000;

GST_ARGUS: Running with following settings:
   Camera index = 0 
   Camera mode  = 2 
   Output Stream W = 1920 H = 1080 
   seconds to Run    = 0 
   Frame Rate = 59,000002 
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.
CONSUMER: Producer has connected; continuing.
H264: Profile = 66, Level = 0 
NVMEDIA: Need to set EMC bandwidth : 846000 
NVMEDIA: Need to set EMC bandwidth : 846000 
NvVideo: bBlitMode is set to TRUE 
WARNING: from element /GstPipeline:pipeline0/GstUDPSink:udpsink0: Pipeline construction is invalid, please add queues.
Additional debug info:
gstbasesink.c(1209): gst_base_sink_query_latency (): /GstPipeline:pipeline0/GstUDPSink:udpsink0:
Not enough buffering available for  the processing deadline of 0:00:00.020000000, add enough queues to buffer  0:00:00.020000000 additional data. Shortening processing latency to 0:00:00.000000000.

Could you advice some solution for both board and remote sides, please ?

Jetpack-5.1.2

Best Regards,
Khang

I just realized that it was not really an error but a warning. Streaming was available.

Regards,
K.

1 Like

Hi,
It suggests add a queue plugin. So you may try

... ! rtph264pay ! queue ! udpsink

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.