← 返回命令列表

Linux command

v4l2loopback-ctl 命令

安全

权限或系统影响较大,执行前请核对目标。

常用示例

Create a new loopback device

sudo v4l2loopback-ctl add -n "[My Virtual Camera]"

List all

v4l2loopback-ctl list

Delete

sudo v4l2loopback-ctl delete /dev/video[0]

Query

v4l2loopback-ctl query /dev/video[0]

Set the frame rate

v4l2loopback-ctl set-fps /dev/video[0] [30]

Set the format capabilities

v4l2loopback-ctl set-caps /dev/video[0] "[UYVY:1024x768@30/1]"

Set a timeout image

v4l2loopback-ctl set-timeout-image -t [3000] /dev/video[0] [path/to/image.png]

说明

v4l2loopback-ctl is a utility for managing virtual video loopback devices created by the v4l2loopback kernel module. These virtual devices act as pipes: one application feeds video frames into the device (producer), and another application reads them (consumer), enabling use cases like virtual webcams, screen sharing to video conferencing tools, and video processing pipelines. The tool uses a verb-based interface with commands for creating, deleting, listing, and querying loopback devices, as well as configuring their frame rate, format capabilities, and fallback timeout images.

参数

-h, -?, --help
Display help information and exit.
-v, --version
Show version and exit.

FAQ

What is the v4l2loopback-ctl command used for?

v4l2loopback-ctl is a utility for managing virtual video loopback devices created by the v4l2loopback kernel module. These virtual devices act as pipes: one application feeds video frames into the device (producer), and another application reads them (consumer), enabling use cases like virtual webcams, screen sharing to video conferencing tools, and video processing pipelines. The tool uses a verb-based interface with commands for creating, deleting, listing, and querying loopback devices, as well as configuring their frame rate, format capabilities, and fallback timeout images.

How do I run a basic v4l2loopback-ctl example?

Run `sudo v4l2loopback-ctl add -n "[My Virtual Camera]"` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does -h, -?, --help do in v4l2loopback-ctl?

Display help information and exit.