Function File: props = set (vi, prop)
Function File: val = set (vi, prop, value)
Function File: val = set (vi, prop, value, …)

Set or modify properties of videoinput objects.

The first variant (without value) returns a struct with possible values or range.

obj = videoinput("v4l2", "/dev/video0");
set (obj, 'brightness')
⇒ scalar structure containing the fields:

   min = 0
   max =  255
   step =  1
   default =  128

There is a number of properties starting with an upper letter which are available on all videoinput devices. Only the non-obvious are described here.

’VideoResolution’

Sets the width and height of the captured images. The driver attemps to adjust the values if the size requested is unavailable.

obj = videoinput("v4l2", "/dev/video0");
set(obj, "VideoResolution", [960 700])
⇒ warning: v4l2_handler::s_fmt: Driver is sending image at 960x720 although 960x700 was requested
’VideoFrameInterval’

Time between frames in seconds as [numerator, denominator]. Conceptually fps=1/frame_interval.

’VideoFormat’

Set the VideoFormat using FOURCC code (for example RGB3) or long name (RGB24). See set(obj, "VideoFormat") for a list.

See also: @videoinput/get.

Package: image-acquisition