blob: a35fc15a313758424b4f8e6d12c6a6c420f50f8a [file] [log] [blame]
Markus Heiser5377d912016-06-30 15:18:56 +02001.. -*- coding: utf-8; mode: rst -*-
2
3.. _media-controller-types:
4
5Types and flags used to represent the media graph elements
6==========================================================
7
8
9.. _media-entity-type:
10
11.. flat-table:: Media entity types
12 :header-rows: 0
13 :stub-columns: 0
14
15
16 - .. row 1
17
18 - ``MEDIA_ENT_F_UNKNOWN`` and ``MEDIA_ENT_F_V4L2_SUBDEV_UNKNOWN``
19
20 - Unknown entity. That generally indicates that a driver didn't
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -030021 initialize properly the entity, with is a Kernel bug
Markus Heiser5377d912016-06-30 15:18:56 +020022
23 - .. row 2
24
25 - ``MEDIA_ENT_F_IO_V4L``
26
27 - Data streaming input and/or output entity.
28
29 - .. row 3
30
31 - ``MEDIA_ENT_F_IO_VBI``
32
33 - V4L VBI streaming input or output entity
34
35 - .. row 4
36
37 - ``MEDIA_ENT_F_IO_SWRADIO``
38
39 - V4L Software Digital Radio (SDR) streaming input or output entity
40
41 - .. row 5
42
43 - ``MEDIA_ENT_F_IO_DTV``
44
45 - DVB Digital TV streaming input or output entity
46
47 - .. row 6
48
49 - ``MEDIA_ENT_F_DTV_DEMOD``
50
51 - Digital TV demodulator entity.
52
53 - .. row 7
54
55 - ``MEDIA_ENT_F_TS_DEMUX``
56
57 - MPEG Transport stream demux entity. Could be implemented on
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -030058 hardware or in Kernelspace by the Linux DVB subsystem.
Markus Heiser5377d912016-06-30 15:18:56 +020059
60 - .. row 8
61
62 - ``MEDIA_ENT_F_DTV_CA``
63
64 - Digital TV Conditional Access module (CAM) entity
65
66 - .. row 9
67
68 - ``MEDIA_ENT_F_DTV_NET_DECAP``
69
70 - Digital TV network ULE/MLE desencapsulation entity. Could be
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -030071 implemented on hardware or in Kernelspace
Markus Heiser5377d912016-06-30 15:18:56 +020072
73 - .. row 10
74
75 - ``MEDIA_ENT_F_CONN_RF``
76
77 - Connector for a Radio Frequency (RF) signal.
78
79 - .. row 11
80
81 - ``MEDIA_ENT_F_CONN_SVIDEO``
82
83 - Connector for a S-Video signal.
84
85 - .. row 12
86
87 - ``MEDIA_ENT_F_CONN_COMPOSITE``
88
89 - Connector for a RGB composite signal.
90
91 - .. row 13
92
93 - ``MEDIA_ENT_F_CAM_SENSOR``
94
95 - Camera video sensor entity.
96
97 - .. row 14
98
99 - ``MEDIA_ENT_F_FLASH``
100
101 - Flash controller entity.
102
103 - .. row 15
104
105 - ``MEDIA_ENT_F_LENS``
106
107 - Lens controller entity.
108
109 - .. row 16
110
111 - ``MEDIA_ENT_F_ATV_DECODER``
112
113 - Analog video decoder, the basic function of the video decoder is
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300114 to accept analogue video from a wide variety of sources such as
115 broadcast, DVD players, cameras and video cassette recorders, in
116 either NTSC, PAL, SECAM or HD format, separating the stream into
117 its component parts, luminance and chrominance, and output it in
118 some digital video standard, with appropriate timing signals.
Markus Heiser5377d912016-06-30 15:18:56 +0200119
120 - .. row 17
121
122 - ``MEDIA_ENT_F_TUNER``
123
124 - Digital TV, analog TV, radio and/or software radio tuner, with
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300125 consists on a PLL tuning stage that converts radio frequency (RF)
126 signal into an Intermediate Frequency (IF). Modern tuners have
127 internally IF-PLL decoders for audio and video, but older models
128 have those stages implemented on separate entities.
Markus Heiser5377d912016-06-30 15:18:56 +0200129
130 - .. row 18
131
132 - ``MEDIA_ENT_F_IF_VID_DECODER``
133
134 - IF-PLL video decoder. It receives the IF from a PLL and decodes
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300135 the analog TV video signal. This is commonly found on some very
136 old analog tuners, like Philips MK3 designs. They all contain a
137 tda9887 (or some software compatible similar chip, like tda9885).
138 Those devices use a different I2C address than the tuner PLL.
Markus Heiser5377d912016-06-30 15:18:56 +0200139
140 - .. row 19
141
142 - ``MEDIA_ENT_F_IF_AUD_DECODER``
143
144 - IF-PLL sound decoder. It receives the IF from a PLL and decodes
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300145 the analog TV audio signal. This is commonly found on some very
146 old analog hardware, like Micronas msp3400, Philips tda9840,
147 tda985x, etc. Those devices use a different I2C address than the
148 tuner PLL and should be controlled together with the IF-PLL video
149 decoder.
Markus Heiser5377d912016-06-30 15:18:56 +0200150
151 - .. row 20
152
153 - ``MEDIA_ENT_F_AUDIO_CAPTURE``
154
155 - Audio Capture Function Entity.
156
157 - .. row 21
158
159 - ``MEDIA_ENT_F_AUDIO_PLAYBACK``
160
161 - Audio Playback Function Entity.
162
163 - .. row 22
164
165 - ``MEDIA_ENT_F_AUDIO_MIXER``
166
167 - Audio Mixer Function Entity.
168
169
170
171.. _media-entity-flag:
172
173.. flat-table:: Media entity flags
174 :header-rows: 0
175 :stub-columns: 0
176
177
178 - .. row 1
179
180 - ``MEDIA_ENT_FL_DEFAULT``
181
182 - Default entity for its type. Used to discover the default audio,
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300183 VBI and video devices, the default camera sensor, ...
Markus Heiser5377d912016-06-30 15:18:56 +0200184
185 - .. row 2
186
187 - ``MEDIA_ENT_FL_CONNECTOR``
188
189 - The entity represents a data conector
190
191
192
193.. _media-intf-type:
194
195.. flat-table:: Media interface types
196 :header-rows: 0
197 :stub-columns: 0
198
199
200 - .. row 1
201
202 - ``MEDIA_INTF_T_DVB_FE``
203
204 - Device node interface for the Digital TV frontend
205
206 - typically, /dev/dvb/adapter?/frontend?
207
208 - .. row 2
209
210 - ``MEDIA_INTF_T_DVB_DEMUX``
211
212 - Device node interface for the Digital TV demux
213
214 - typically, /dev/dvb/adapter?/demux?
215
216 - .. row 3
217
218 - ``MEDIA_INTF_T_DVB_DVR``
219
220 - Device node interface for the Digital TV DVR
221
222 - typically, /dev/dvb/adapter?/dvr?
223
224 - .. row 4
225
226 - ``MEDIA_INTF_T_DVB_CA``
227
228 - Device node interface for the Digital TV Conditional Access
229
230 - typically, /dev/dvb/adapter?/ca?
231
232 - .. row 5
233
234 - ``MEDIA_INTF_T_DVB_FE``
235
236 - Device node interface for the Digital TV network control
237
238 - typically, /dev/dvb/adapter?/net?
239
240 - .. row 6
241
242 - ``MEDIA_INTF_T_V4L_VIDEO``
243
244 - Device node interface for video (V4L)
245
246 - typically, /dev/video?
247
248 - .. row 7
249
250 - ``MEDIA_INTF_T_V4L_VBI``
251
252 - Device node interface for VBI (V4L)
253
254 - typically, /dev/vbi?
255
256 - .. row 8
257
258 - ``MEDIA_INTF_T_V4L_RADIO``
259
260 - Device node interface for radio (V4L)
261
262 - typically, /dev/vbi?
263
264 - .. row 9
265
266 - ``MEDIA_INTF_T_V4L_SUBDEV``
267
268 - Device node interface for a V4L subdevice
269
270 - typically, /dev/v4l-subdev?
271
272 - .. row 10
273
274 - ``MEDIA_INTF_T_V4L_SWRADIO``
275
276 - Device node interface for Software Defined Radio (V4L)
277
278 - typically, /dev/swradio?
279
280 - .. row 11
281
282 - ``MEDIA_INTF_T_ALSA_PCM_CAPTURE``
283
284 - Device node interface for ALSA PCM Capture
285
286 - typically, /dev/snd/pcmC?D?c
287
288 - .. row 12
289
290 - ``MEDIA_INTF_T_ALSA_PCM_PLAYBACK``
291
292 - Device node interface for ALSA PCM Playback
293
294 - typically, /dev/snd/pcmC?D?p
295
296 - .. row 13
297
298 - ``MEDIA_INTF_T_ALSA_CONTROL``
299
300 - Device node interface for ALSA Control
301
302 - typically, /dev/snd/controlC?
303
304 - .. row 14
305
306 - ``MEDIA_INTF_T_ALSA_COMPRESS``
307
308 - Device node interface for ALSA Compress
309
310 - typically, /dev/snd/compr?
311
312 - .. row 15
313
314 - ``MEDIA_INTF_T_ALSA_RAWMIDI``
315
316 - Device node interface for ALSA Raw MIDI
317
318 - typically, /dev/snd/midi?
319
320 - .. row 16
321
322 - ``MEDIA_INTF_T_ALSA_HWDEP``
323
324 - Device node interface for ALSA Hardware Dependent
325
326 - typically, /dev/snd/hwC?D?
327
328 - .. row 17
329
330 - ``MEDIA_INTF_T_ALSA_SEQUENCER``
331
332 - Device node interface for ALSA Sequencer
333
334 - typically, /dev/snd/seq
335
336 - .. row 18
337
338 - ``MEDIA_INTF_T_ALSA_TIMER``
339
340 - Device node interface for ALSA Timer
341
342 - typically, /dev/snd/timer
343
344
345
346.. _media-pad-flag:
347
348.. flat-table:: Media pad flags
349 :header-rows: 0
350 :stub-columns: 0
351
352
353 - .. row 1
354
355 - ``MEDIA_PAD_FL_SINK``
356
357 - Input pad, relative to the entity. Input pads sink data and are
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300358 targets of links.
Markus Heiser5377d912016-06-30 15:18:56 +0200359
360 - .. row 2
361
362 - ``MEDIA_PAD_FL_SOURCE``
363
364 - Output pad, relative to the entity. Output pads source data and
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300365 are origins of links.
Markus Heiser5377d912016-06-30 15:18:56 +0200366
367 - .. row 3
368
369 - ``MEDIA_PAD_FL_MUST_CONNECT``
370
371 - If this flag is set and the pad is linked to any other pad, then
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300372 at least one of those links must be enabled for the entity to be
373 able to stream. There could be temporary reasons (e.g. device
374 configuration dependent) for the pad to need enabled links even
375 when this flag isn't set; the absence of the flag doesn't imply
376 there is none.
Markus Heiser5377d912016-06-30 15:18:56 +0200377
378
379One and only one of ``MEDIA_PAD_FL_SINK`` and ``MEDIA_PAD_FL_SOURCE``
380must be set for every pad.
381
382
383.. _media-link-flag:
384
385.. flat-table:: Media link flags
386 :header-rows: 0
387 :stub-columns: 0
388
389
390 - .. row 1
391
392 - ``MEDIA_LNK_FL_ENABLED``
393
394 - The link is enabled and can be used to transfer media data. When
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300395 two or more links target a sink pad, only one of them can be
396 enabled at a time.
Markus Heiser5377d912016-06-30 15:18:56 +0200397
398 - .. row 2
399
400 - ``MEDIA_LNK_FL_IMMUTABLE``
401
402 - The link enabled state can't be modified at runtime. An immutable
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300403 link is always enabled.
Markus Heiser5377d912016-06-30 15:18:56 +0200404
405 - .. row 3
406
407 - ``MEDIA_LNK_FL_DYNAMIC``
408
409 - The link enabled state can be modified during streaming. This flag
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300410 is set by drivers and is read-only for applications.
Markus Heiser5377d912016-06-30 15:18:56 +0200411
412 - .. row 4
413
414 - ``MEDIA_LNK_FL_LINK_TYPE``
415
416 - This is a bitmask that defines the type of the link. Currently,
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300417 two types of links are supported:
Markus Heiser5377d912016-06-30 15:18:56 +0200418
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300419 ``MEDIA_LNK_FL_DATA_LINK`` if the link is between two pads
Markus Heiser5377d912016-06-30 15:18:56 +0200420
Mauro Carvalho Chehab0579e6e2016-07-04 16:25:48 -0300421 ``MEDIA_LNK_FL_INTERFACE_LINK`` if the link is between an
422 interface and an entity