but use the pixel format NvBufferColorFormat_NV12 is not corrupt. I really dont konw why?
the gdb info as follow:
#0 0x0000007fb4b53528 in __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:54
#1 0x0000007fb4b549e0 in __GI_abort () at abort.c:89
#2 0x0000007fb4b8a8c4 in __libc_message (do_abort=do_abort@entry=2, fmt=fmt@entry=0x7fb4c3b550 "*** Error in `%s': %s: 0x%s ***\n") at ../sysdeps/posix/libc_fatal.c:175
#3 0x0000007fb4b902ec in malloc_printerr (action=<optimized out>, str=0x7fb4c3b628 "double free or corruption (!prev)", ptr=<optimized out>, ar_ptr=<optimized out>) at malloc.c:5006
#4 0x0000007fb4b91088 in _int_free (av=0x7fb4c639a0 <main_arena>, p=<optimized out>, have_lock=0) at malloc.c:3867
<b>#5 0x0000007fb6ed9b6c in NvBufferCreate () from /usr/lib/aarch64-linux-gnu/tegra/libnvbuf_utils.so.1.0.0</b>
#6 0x000000000041208c in ArgusSamples::stitch_vic_init () at main.cpp:1405
#7 0x0000000000413070 in main (argc=5, argv=0x7ffffff4c8) at main.cpp:1843
(gdb)
We are using 4 cameras, it means 4 threads running to get frames from argus API. then convert to ABGR32 to handle the rgb iamge.
One VIC to convert the ABGR32 to YUV42M, then feed to One encoder for RTMP.
The camera we are using are OV4689 with NV ISP.
NvBufferCreate will be corrupt with ABGR32 format. I tried to place it at the beginning of the main(), it corrupt, just follow the args API it corrupt. looks like it will corrupt with NV ISP enabled.
We tried to using OV5645 with almost the same pipe line but with V4l2 to get framte. it works fine.
Yes, I know that, We convert from argus ouput to BGRA. then handle the BGRA image, after that we create a NVBUFFER with format BGRA, so that we can convert the BGRA to YUV420M for encoder input.
We flush a new ubuntu os and instll essential packages ,and test use ov5693, it will also corrupt.we put the NvBufferCreate on the first line of main() function. The code as follow: