2020-08-26 09:03:09 +02:00
|
|
|
.. SPDX-License-Identifier: GFDL-1.1-no-invariants-or-later
|
2018-08-30 10:15:26 -04:00
|
|
|
|
2016-06-30 15:18:56 +02:00
|
|
|
.. _common:
|
|
|
|
|
|
|
|
###################
|
|
|
|
Common API Elements
|
|
|
|
###################
|
|
|
|
Programming a V4L2 device consists of these steps:
|
|
|
|
|
|
|
|
- Opening the device
|
|
|
|
|
|
|
|
- Changing device properties, selecting a video and audio input, video
|
|
|
|
standard, picture brightness a. o.
|
|
|
|
|
|
|
|
- Negotiating a data format
|
|
|
|
|
|
|
|
- Negotiating an input/output method
|
|
|
|
|
|
|
|
- The actual input/output loop
|
|
|
|
|
|
|
|
- Closing the device
|
|
|
|
|
|
|
|
In practice most steps are optional and can be executed out of order. It
|
|
|
|
depends on the V4L2 device type, you can read about the details in
|
|
|
|
:ref:`devices`. In this chapter we will discuss the basic concepts
|
|
|
|
applicable to all devices.
|
|
|
|
|
|
|
|
|
|
|
|
.. toctree::
|
|
|
|
:maxdepth: 1
|
|
|
|
|
|
|
|
open
|
|
|
|
querycap
|
|
|
|
app-pri
|
|
|
|
video
|
|
|
|
audio
|
|
|
|
tuner
|
|
|
|
standard
|
|
|
|
dv-timings
|
2016-07-02 08:37:16 -03:00
|
|
|
control
|
|
|
|
extended-controls
|
2019-02-08 10:53:50 +01:00
|
|
|
ext-ctrls-camera
|
|
|
|
ext-ctrls-flash
|
|
|
|
ext-ctrls-image-source
|
|
|
|
ext-ctrls-image-process
|
|
|
|
ext-ctrls-codec
|
2020-11-26 10:36:18 +01:00
|
|
|
ext-ctrls-codec-stateless
|
2019-02-08 10:53:50 +01:00
|
|
|
ext-ctrls-jpeg
|
|
|
|
ext-ctrls-dv
|
|
|
|
ext-ctrls-rf-tuner
|
|
|
|
ext-ctrls-fm-tx
|
|
|
|
ext-ctrls-fm-rx
|
|
|
|
ext-ctrls-detect
|
2020-03-06 08:34:41 +01:00
|
|
|
fourcc
|
2016-06-30 15:18:56 +02:00
|
|
|
format
|
|
|
|
planar-apis
|
|
|
|
selection-api
|
2018-05-14 07:27:24 -04:00
|
|
|
crop
|
2016-06-30 15:18:56 +02:00
|
|
|
streaming-par
|