3 (defcstruct v4l2-capability
4 (driver :uchar
:count
16)
5 (card :uchar
:count
32)
6 (bus-info :uchar
:count
32)
9 (reserved :uint32
:count
4))
11 (defcstruct v4l2-fract
13 (denominator :uint32
))
15 (defcstruct v4l2-captureparm
16 (capability :uint32
) ; Supported modes
17 (capturemode :uint32
) ; Current mode
18 (timeperframe v4l2-fract
) ; Time per frame in .1us units
19 (extendedmode :uint32
) ; Driver-specific extensions
20 (readbuffers :uint32
) ; # of buffers for read
21 (reserved :uint32
:count
4))
23 (defcstruct v4l2-outputparm
24 (capability :uint32
) ; Supported modes
25 (outputmode :uint32
) ; Current mode
26 (timeperframe v4l2-fract
) ; Time per frame in .1us units
27 (extendedmode :uint32
) ; Driver-specific extensions
28 (writebuffers :uint32
) ; # of buffers for write
29 (reserved :uint32
:count
4))
31 (defcunion v4l2-streamparm-union
32 (capture v4l2-captureparm
)
33 (output v4l2-outputparm
)
34 (raw-data :uchar
:count
200))
36 (defcenum v4l2-buf-type
37 (:buf-type-video-capture
1)
38 :buf-type-video-output
39 :buf-type-video-overlay
42 :buf-type-sliced-vbi-capture
43 :buf-type-sliced-vbi-output
44 :buf-type-video-output-overlay
)
46 (defcstruct v4l2-streamparm
48 (parm v4l2-streamparm-union
))
50 (defcenum v4l2-tuner-type
55 (defcstruct v4l2-tuner
57 (name :uchar
:count
32)
58 (type v4l2-tuner-type
)
66 (reserved :uint32
:count
4))
68 (defcstruct v4l2-standard
71 (name :uchar
:count
24)
72 (frameperiod v4l2-fract
)
74 (reserved :uint32
:count
4))
76 (defcstruct v4l2-input
77 (index :uint32
) ; Which input
78 (name :uchar
:count
32) ; Label
79 (type :uint32
) ; Type of input
80 (audioset :uint32
) ; Associated audios (bitfield)
81 (tuner :uint32
) ; Associated tuner
84 (reserved :uint32
:count
4))
87 ;; F O R M A T E N U M E R A T I O N
89 (defcstruct v4l2-fmtdesc
90 (index :uint32
) ; Format number
91 (type v4l2-buf-type
) ; buffer type
93 (description :uchar
:count
32) ; Description string
94 (pixelformat :uint32
) ; Format fourcc
95 (reserved :uint32
:count
4))
97 ;; Values for the 'type' field
98 (defconstant v4l2-input-type-tuner
1)
100 (defconstant v4l2-input-type-camera
2)
103 :field-any
; driver can choose from none
104 ; top, bottom, interlaced
105 ; depending on whatever it thinks
107 :field-none
; this device has no fields ...
108 :field-top
; top field only
109 :field-bottom
; bottom field only
110 :field-interlaced
; both fields interlaced
111 :field-seq-tb
; both fields sequential into one
112 ; buffer, top-bottom order
113 :field-seq-bt
; same as above + bottom-top order
114 :field-alternate
; both fields alternating into
116 :field-interlaced-tb
; both fields interlaced, top field
117 ; first and the top field is
119 :field-interlaced-bt
; both fields interlaced, top field
120 ; first and the bottom field is
124 (defcenum v4l2-colorspace
125 (:colorspace-smpte170m
1) ; ITU-R 601 -- broadcast NTSC/PAL
126 :colorspace_smpte240m
; 1125-Line (US) HDTV
127 :colorspace-rec709
; HD and modern captures.
128 ; broken BT878 extents (601, luma range 16-253 instead of 16-235)
130 ; These should be useful. Assume 601 extents.
131 :colorspace-470-system-m
132 :colorspace-470-system-bg
134 ; I know there will be cameras that send this. So, this is
135 ; unspecified chromaticities and full 0-255 on each of the
139 ; For RGB colourspaces, this is probably a good start.
143 ;; V I D E O I M A G E F O R M A T
145 (defcstruct v4l2-pix-format
148 (pixelformat :uint32
)
150 (bytesperline :uint32
) ; for padding, zero if unused
152 (colorspace v4l2-colorspace
)
153 (priv :uint32
)) ; private data, depends on pixelformat
155 ;; Stream data format
158 (defcstruct v4l2-timecode
165 (userbits :uchar
:count
4))
167 (defcenum v4l2-memory
172 ;; M E M O R Y - M A P P I N G B U F F E R S
174 (defcstruct v4l2-requestbuffers
178 (reserved :uint32
:count
2))
180 (defcunion v4l2-buffer-union
184 (defcstruct v4l2-buffer
191 (timecode v4l2-timecode
)
195 (m v4l2-buffer-union
)