v4l2caps¶
Video for Linux capture plugin
Description¶
Video for Linux is a video capture application programming interface(API) and library for Linux. The library supports many USB web cams, TV tuners as well as other devices and is the common way to access multimedia devices under Linux. The v4l2caps plugin uses the Video for Linux API to capture frames from compatible hardware devices and stores each frame into CAPS. Available resolutions, pixel formats and other parameters depend on the used device. See the manual of the hardware manufacturer for more details. The capture process of the plugin gets a frame in a given sampling interval. For each frame a new ANY packet is created which uses the sampling time of the frame as start and end time for the packet. In addition the format of the packet is set to the selected pixel format. Frame drops may occur when the storage system is not fast enough to handle incoming data.
Examples¶
To capture 15 images per second (the maximum number of images depends on your hardware) and store the output into CAPS use:
$ v4l2caps -s SW.HMA.317.CAM --interval 15/1
Module Configuration¶
etc/defaults/global.cfg
etc/defaults/v4l2caps.cfg
etc/global.cfg
etc/v4l2caps.cfg
~/.seiscomp/global.cfg
~/.seiscomp/v4l2caps.cfg
v4l2caps inherits global options.
Note
Modules/plugins may require a license file. The default path to license
files is @DATADIR@/licenses/
which can be overridden by global
configuration of the parameter gempa.licensePath
. Example:
gempa.licensePath = @CONFIGDIR@/licenses
- host¶
Default:
localhost
Type: string
Data output host
- port¶
Default:
18003
Type: uint
Data output host
- streamID¶
Type: string
Stream ID to use, format is [net.sta.loc.cha]
- resolution¶
Type: string
Resolution to use
- outputFormat¶
Type: string
Output format to use [rgb, jpg]
- outputQuality¶
Default:
100
Type: int
Output quality to use [0-100]
- interval¶
Type: uint
Sampling interval to use, format is [Denominator/Numerator]
- pixelFormat¶
Type: string
Pixel format to use, expected as four character code[ABCD]
- count¶
Default:
0
Type: uint
Number of frames to grab
- skip¶
Default:
0
Type: uint
Number of frames to skip
- bufferSize¶
Default:
1048576
Type: uint
Size (bytes) of the internal buffer to keep still unconfirmed packages
- device¶
Default:
/dev/video0
Type: string
Video device name
- io¶
Default:
1
Type: uint
I/O method. 0: Use read function, 1: Use memory mapped buffers
Command-Line Options¶
- -b, --buffer-size arg¶
Size (bytes) of the internal buffer to keep still unconfirmed packages
- -c, --count arg¶
Number of frames to grab
- --config arg¶
Path to configuration file
- -d, --device arg¶
Video device name
- --dump arg¶
Dump output to file
- -f, --pixel-format arg¶
Pixel format to use, expected as four character code[ABCD]
- -F, --output-format arg¶
Output format to use [rgb, jpg]
- -H, --host arg¶
Data output host
- -h, --help arg¶
Print help
- --info arg¶
Print device info
- -i, --interval arg¶
Sampling interval to use, format is [Denominator/Numerator]
- --io arg¶
I/O method. 0: Use read function, 1: Use memory mapped buffers [default]
- -p, --port arg¶
Data output port
- -q, --output-quality arg¶
Output quality to use [0-100]
- -r, --resolution arg¶
Resolution to use
- -s, --stream-id arg¶
Stream ID to use, format is [net.sta.loc.cha]
- -S, --skip arg¶
Number of frames to skip