I am trying to merge frames from two usb cameras side by side with gst-launch-1.0 using nvcompositor similar to the example given in the developer wiki
The input looks as as follows:
gst-launch-1.0 nvcompositor name=comp sink_0::xpos=0 sink_0::ypos=0 sink_0::width=640 sink_0::height=480 sink_1::xpos=640 sink_1::ypos=0 sink_1::width=640 sink_1::height=480 ! nvoverlaysink v4l2src device=“/dev/video0” io-mode=2 ! ‘image/jpeg,width=640,height=480’ ! nvv4l2decoder mjpeg=1 ! nvvidconv ! ‘video/x-raw(memory:NVMM),format=RGBA’ ! comp. v4l2src device=“/dev/video1” io-mode=2 ! ‘image/jpeg,width=640,height=480’ ! nvv4l2decoder mjpeg=1 ! nvvidconv ! ‘video/x-raw(memory:NVMM),format=RGBA’ ! comp.
The error message is as follows:
Setting pipeline to PAUSED …
Opening in BLOCKING MODE
Opening in BLOCKING MODE
Opening in BLOCKING MODE
Opening in BLOCKING MODE
Opening in BLOCKING MODE
Caught SIGSEGV
#0 0x0000007f9a2add5c in __waitpid (pid=, stat_loc=0x7fda0d2454, options=) at …/sysdeps/unix/sysv/linux/waitpid.c:30
#1 0x0000007f9a2e92e0 in g_on_error_stack_trace ()
#2 0x000000558ccaac3c in ()
#3 0x0000000000008600 in ()
Spinning. Please run ‘gdb gst-launch-1.0 521’ to continue debugging, Ctrl-C to quit, or Ctrl-\ to dump core.
gdb gst-launch-1.0 521 returns the following:
GNU gdb (Ubuntu 8.1.1-0ubuntu1) 8.1.1
Copyright (C) 2018 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type “show copying”
and “show warranty” for details.
This GDB was configured as “aarch64-linux-gnu”.
Type “show configuration” for configuration details.
For bug reporting instructions, please see:
http://www.gnu.org/software/gdb/bugs/.
Find the GDB manual and other documentation resources online at:
http://www.gnu.org/software/gdb/documentation/.
For help, type “help”.
Type “apropos word” to search for commands related to “word”…
Reading symbols from gst-launch-1.0…(no debugging symbols found)…done.
Attaching to program: /usr/bin/gst-launch-1.0, process 521
[New LWP 522]
[New LWP 524]
[Thread debugging using libthread_db enabled]
Using host libthread_db library “/lib/aarch64-linux-gnu/libthread_db.so.1”.
0x0000007f9a2ad5fc in __GI___nanosleep (requested_time=0x7fda0d2468,
remaining=0x7fda0d2478) at …/sysdeps/unix/sysv/linux/nanosleep.c:28
28 …/sysdeps/unix/sysv/linux/nanosleep.c: No such file or directory.
I am able to run both cameras simultaneously in two separate windows with:
gst-launch-1.0 v4l2src device=“/dev/video0” ! ‘image/jpeg,width=1920,height=1080’ ! nvv4l2decoder mjpeg=1 ! nvvidconv ! ‘video/x-raw(memory:NVMM),format=RGBA’ ! nvoverlaysink
I wonder why, I cant merge the video streams…