Hello everyone,
I have been trying to record a video stream from an IMX252 monochrome camera using a Jetson NX and developer board. I am using gstreamer to record this camera. Prior to running my gstreamer pipeline, I use v4l2-ctl to set the camera settings. These are the settings I set:
v4l2-ctl -d /dev/video0 --set-ctrl frame_rate=60 --set-ctrl gain=50 --set-ctrl exposure=1000
This is one of the gstreamer pipelines I am using:
gst-launch-1.0 -v v4l2src device=/dev/video0 ! 'video/x-raw, width=2048, height=1536, format=GRAY8' ! nvvidconv ! videoconvert ! nvjpegenc ! qtmux name=mux ! filesink location=test.mov sync=false -e
In this pipeline I am able to encode a video using nvjpegenc into an mov file. When I launch the mov file on VLC and open the codec information I get:
As you can see the camera is not recording at 60 FPS and the colorspace is not GRAY8.
The second pipeline I have tried is this:
gst-launch-1.0 -v v4l2src device=/dev/video0 ! 'video/x-raw, width=2048, height=1536, format=GRAY8' ! nvvidconv ! videoconvert ! 'video/x-raw, format=GRAY8' ! nvjpegenc ! qtmux name=mux ! filesink location=test2.mov sync=false -e
In this pipeline I am forcing the NVJPEGENC to use GRAY8 as the colorspace but the video only records at 10FPS.
I am aware that nvarguscamerasrc will not work with a monochrome camera because that src does not support grayscale. Actually, not much from nvidias libraries support grayscale, that is the reason why I am using v4l2src. Does anyone know why I cannot encode at 60FPS? The camera driver supports up to 120fps so 60fps should be no problem. Any help or advice is greatly appreciated.
Thank you,
Frank