We are unable to get nvcompositor working on jetpack 6.1.
gst-launch-1.0 nvcompositor name=comp ! 'video/x-raw(memory:NVMM),width=(int)1280,height=(int)720,framerate=60/1,format=(string)RGBA' ! fakesink nvarguscamerasrc sensor-id=0 ! 'video/x-raw(memory:NVMM),width=(int)1280,height=(int)720,framerate=60/1,format=(string)NV12' ! nvvidconv ! 'video/x-raw(memory:NVMM),width=(int)1280,height=(int)720,framerate=60/1,format=(string)RGBA' ! comp.sink_0
Setting pipeline to PAUSED ...
Pipeline is live and does not need PREROLL ...
Pipeline is PREROLLED ...
Setting pipeline to PLAYING ...
New clock: GstSystemClock
Redistribute latency...
GST_ARGUS: Creating output stream
Redistribute latency...
CONSUMER: Waiting until producer is connected...
GST_ARGUS: Available Sensor modes :
GST_ARGUS: 3280 x 2464 FR = 21.000000 fps Duration = 47619048 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;
GST_ARGUS: 3280 x 1848 FR = 28.000001 fps Duration = 35714284 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;
GST_ARGUS: 1920 x 1080 FR = 29.999999 fps Duration = 33333334 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;
GST_ARGUS: 1640 x 1232 FR = 29.999999 fps Duration = 33333334 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;
GST_ARGUS: 1280 x 720 FR = 59.999999 fps Duration = 16666667 ; Analog Gain range min 1.000000, max 10.625000; Exposure Range min 13000, max 683709000;
GST_ARGUS: Running with following settings:
Camera index = 0
Camera mode = 4
Output Stream W = 1280 H = 720
seconds to Run = 0
Frame Rate = 59.999999
GST_ARGUS: Setup Complete, Starting captures for 0 seconds
GST_ARGUS: Starting repeat capture requests.
CONSUMER: Producer has connected; continuing.
nvbuf_utils: dmabuf_fd -1 mapped entry NOT found
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, threadExecute:734 NvBufSurfaceFromFd Failed.
Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, threadFunction:245 (propagating)
Got EOS from element "pipeline0".
Execution ended after 0:00:04.078024553
Setting pipeline to NULL ...
GST_ARGUS: Cleaning up
GST_ARGUS: Done Success
Freeing pipeline ...
Additionally running:
gst-launch-1.0 nvarguscamerasrc sensor-id=1 ! nvcompositor ! nvvidconv ! fakesink
results in a segfault somewhere in nvcompositor:
(gdb) backtrace
#0 0x0000fffff59163d4 in () at /usr/lib/aarch64-linux-gnu/nvidia/libnvbufsurftransform.so.1.0.0
#1 0x0000fffff591bcb0 [PAC] in () at /usr/lib/aarch64-linux-gnu/nvidia/libnvbufsurftransform.so.1.0.0
#2 0x0000ffffed7e50e0 [PAC] in () at /home/otiv-host/nvidia/libs/libgstnvcompositor.so
#3 0x0000fffff6fd722c [PAC] in gst_video_aggregator_aggregate () at /home/otiv-host/github/gstreamer/builddir/subprojects/gst-plugins-base/gst-libs/gst/video/libgstvideo-1.0.so.0
#4 0x0000fffff70cf21c in gst_aggregator_aggregate_func () at /home/otiv-host/github/gstreamer/builddir/subprojects/gstreamer/libs/gst/base/libgstbase-1.0.so.0
#5 0x0000fffff7f169ec in gst_task_func () at /home/otiv-host/github/gstreamer/builddir/subprojects/gstreamer/gst/libgstreamer-1.0.so.0
#6 0x0000fffff7d57668 in () at /lib/aarch64-linux-gnu/libglib-2.0.so.0
#7 0x0000fffff7d54990 in () at /lib/aarch64-linux-gnu/libglib-2.0.so.0
#8 0x0000fffff7b1d5c8 in start_thread (arg=0x0) at ./nptl/pthread_create.c:442
#9 0x0000fffff7b85edc in thread_start () at ../sysdeps/unix/sysv/linux/aarch64/clone.S:79
Additionally running our actual production pipeline throws the following error:
0:00:00.851260960 1770 0xaaaad5492d20 WARN videoaggregator gstvideoaggregator.c:1150:gst_video_aggregator_find_best_format:<nvcompositor0> Nothing compatible with video/x-raw(memory:NVMM), format=(string)RGBA, width=(int)1280, height=(int)1080, framerate=(fraction)15/1, pixel-aspect-ratio=(fraction)[ 1/2147483647, 2147483647/1 ]; video/x-raw(memory:NVMM), format=(string)RGBA, width=(int)[ 1, 2147483647 ], height=(int)[ 1, 2147483647 ], framerate=(fraction)15/1, pixel-aspect-ratio=(fraction)[ 1/2147483647, 2147483647/1 ]
0:00:00.851346112 1770 0xaaaad5492d20 WARN nvcompositor gstnvcompositor.c:826:gst_nvcompositor_fixate_caps:<nvcompositor0> This pad is invalid
0:00:00.851363040 1770 0xaaaad5492d20 WARN nvcompositor gstnvcompositor.c:826:gst_nvcompositor_fixate_caps:<nvcompositor0> This pad is invalid
0:00:00.851371712 1770 0xaaaad5492d20 WARN nvcompositor gstnvcompositor.c:826:gst_nvcompositor_fixate_caps:<nvcompositor0> This pad is invalid
0:00:00.851510144 1770 0xaaaad5492c00 FIXME basesink gstbasesink.c:3399:gst_base_sink_default_event:<appsink0> stream-start event without group-id. Consider implementing group-id handling in the upstream elements
There seems to be something going wrong with the conversion from NV12 to RGBA? But I’m not able to pinpoint it.
The following works just fine:
GST_DEBUG=3 gst-launch-1.0 nvarguscamerasrc sensor-id=0 ! nvvidconv ! fakesink