Can't change framerate with v4l2, but can change with Gstreamer

Device: Orin Jetpack 5.1.2

I cannot change my Econ Camera framerate with v4l2:

$ v4l2-ctl -d /dev/video0 --set-parm=30
Frame rate set to 60.000 fps
$ v4l2-ctl --device /dev/video0 --get-parm
Streaming Parameters Video Capture:
	Capabilities     : timeperframe
	Frames per second: 60.000 (60/1)
	Read buffers     : 0

But I can with GStreamer

$ gst-launch-1.0 v4l2src device=/dev/video0 ! 'video/x-raw, framerate=(fraction)30/1' ! fakesink
$ v4l2-ctl --device /dev/video0 --get-parm
Streaming Parameters Video Capture:
	Capabilities     : timeperframe
	Frames per second: 30.000 (30/1)
	Read buffers     : 0

Why is this?

I don’t think default v4l2src support it. If you need it you may need to add it to the v4l2src.

Thanks

Thanks. How would I go about doing that?

Get the v4l2src open source code to customize it.

Thanks

Sorry misunderstand your description.
Use below command to change the framerate by v4l2-ctl.

nvidia@nvidia-desktop:~$ v4l2-ctl ---set-ctrl frame_rate=20000000
nvidia@nvidia-desktop:~$ v4l2-ctl -C frame_rate
frame_rate: 20000000

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.