Crash using nvgstcapture-1.0 to record video

I was following this guide to test my camera

I can see preview display on my screen, take a picture and save to my disk. Everything was working perfectly.

But when I record a video, using command
nvgstcapture-1.0 --mode=2 --camsrc=0

I got error

bitrate = 4000000
Encoder Profile = High
Encoder control-rate = 1
Encoder EnableTwopassCBR = 0
opening in blocking mode
opening in blocking mode
opening in blocking mode
segmentation fault (core dumped)

No matter change the mode from still mode to video mode, or simply type nvgstcapture-1.0 --mode=2 --camsrc=0, same error keep poping up.

Any idea would be appreciated.

hello djjbxxz,

what’s the camera type you’re using, is it CSI camera or USB camera?
in addition, may I know which JetPack release you’re working on, please check release tag for details.
for example, $ cat /etc/nv_tegra_release

I am using an USB Camera and jetpack release 5.1.

please refer to source code - #19 by JerryChang and apply the bug fixes.