• Home
  • Raw
  • Download

Lines Matching +full:data +full:- +full:lines

1 .. -*- coding: utf-8; mode: rst -*-
6 Sliced VBI Data Interface
10 lines of an analog video signal. During VBI no picture information is
14 Sliced VBI devices use hardware to demodulate data transmitted in the
16 :ref:`raw VBI interface <raw-vbi>`. The data is passed as short
27 Different file descriptors must be used to pass raw and sliced VBI data
53 .. _sliced-vbi-format-negotitation:
58 To find out which data services are supported by the hardware
64 lines the hardware can capture or output per frame, or the number of
84 all services may be supported by the hardware on all lines (this is
99 :ref:`read() <func-read>`, :ref:`write() <func-write>` and
100 :ref:`select() <func-select>` call.
106 -----------------------------
118 .. flat-table::
119 :header-rows: 0
120 :stub-columns: 0
123 * - __u32
124 - ``service_set``
125 - :cspan:`2`
127 If ``service_set`` is non-zero when passed with
133 a driver for the cx25840 video decoder sets lines 7-22 of both
143 * - __u16
144 - ``service_lines``\ [2][24]
145 - :cspan:`2`
147 Applications initialize this array with sets of data services the
155 Data services are defined in :ref:`vbi-services2`. Array indices
156 map to ITU-R line numbers\ [#f2]_ as follows:
157 * -
158 -
159 - Element
160 - 525 line systems
161 - 625 line systems
162 * -
163 -
164 - ``service_lines``\ [0][1]
165 - 1
166 - 1
167 * -
168 -
169 - ``service_lines``\ [0][23]
170 - 23
171 - 23
172 * -
173 -
174 - ``service_lines``\ [1][1]
175 - 264
176 - 314
177 * -
178 -
179 - ``service_lines``\ [1][23]
180 - 286
181 - 336
182 * -
183 -
184 - :cspan:`2` Drivers must set ``service_lines`` [0][0] and
191 * - __u32
192 - ``io_size``
193 - :cspan:`2` Maximum number of bytes passed by one
194 :ref:`read() <func-read>` or :ref:`write() <func-write>` call,
200 number of non-zero elements in the returned ``service_lines``
201 array (that is the number of lines potentially carrying data).
202 * - __u32
203 - ``reserved``\ [2]
204 - :cspan:`2` This array is reserved for future extensions.
212 .. _vbi-services2:
215 -------------------
223 .. flat-table::
224 :header-rows: 1
225 :stub-columns: 0
228 * - Symbol
229 - Value
230 - Reference
231 - Lines, usually
232 - Payload
233 * - ``V4L2_SLICED_TELETEXT_B`` (Teletext System B)
234 - 0x0001
235 - :ref:`ets300706`,
238 - PAL/SECAM line 7-22, 320-335 (second field 7-22)
239 - Last 42 of the 45 byte Teletext packet, that is without clock
240 run-in and framing code, lsb first transmitted.
241 * - ``V4L2_SLICED_VPS``
242 - 0x0400
243 - :ref:`ets300231`
244 - PAL line 16
245 - Byte number 3 to 15 according to Figure 9 of ETS 300 231, lsb
247 * - ``V4L2_SLICED_CAPTION_525``
248 - 0x1000
249 - :ref:`cea608`
250 - NTSC line 21, 284 (second field 21)
251 - Two bytes in transmission order, including parity bit, lsb first
253 * - ``V4L2_SLICED_WSS_625``
254 - 0x4000
255 - :ref:`itu1119`,
258 - PAL/SECAM line 23
259 -
266 * - ``V4L2_SLICED_VBI_525``
267 - 0x1000
268 - :cspan:`2` Set of services applicable to 525 line systems.
269 * - ``V4L2_SLICED_VBI_625``
270 - 0x4401
271 - :cspan:`2` Set of services applicable to 625 line systems.
279 read or write data without prior format negotiation, after switching the
287 :ref:`read() <func-read>` or :ref:`write() <func-write>` call).
290 Reading and writing sliced VBI data
293 A single :ref:`read() <func-read>` or :ref:`write() <func-write>`
294 call must pass all data belonging to one video frame. That is an array
297 in streaming I/O mode one buffer of ``io_size`` bytes must contain data
305 ---------------------------
309 .. flat-table::
310 :header-rows: 0
311 :stub-columns: 0
314 * - __u32
315 - ``id``
316 - A flag from :ref:`vbi-services` identifying the type of data in
321 contents of the ``data`` field are undefined and the driver must
322 no longer insert data on the requested ``field`` and ``line``.
323 * - __u32
324 - ``field``
325 - The video field number this data has been captured from, or shall
328 * - __u32
329 - ``line``
330 - The field (as opposed to frame) line number this data has been
331 captured from, or shall be inserted at. See :ref:`vbi-525` and
332 :ref:`vbi-625` for valid values. Sliced VBI capture devices can
334 reliably identify scan lines. The field number must always be
336 * - __u32
337 - ``reserved``
338 - This field is reserved for future extensions. Applications and
340 * - __u8
341 - ``data``\ [48]
342 - The packet payload. See :ref:`vbi-services` for the contents and
343 number of bytes passed for each data type. The contents of padding
349 duplicate line numbers. The :ref:`write() <func-write>` function and
361 captured frame does not carry any of the requested data services drivers
363 VBI data in time for output, the driver must output the last VPS and WSS
365 data, or output data which is ignored by Closed Caption and Teletext
371 synchronizing video and VBI data by using buffer timestamps.
374 Sliced VBI Data in MPEG Streams
379 :ref:`negotiated sliced VBI services <sliced-vbi-format-negotitation>`
380 as data embedded in the MPEG stream. Users or applications control this
381 sliced VBI data insertion with the
382 :ref:`V4L2_CID_MPEG_STREAM_VBI_FMT <v4l2-mpeg-stream-vbi-fmt>`
386 :ref:`V4L2_CID_MPEG_STREAM_VBI_FMT <v4l2-mpeg-stream-vbi-fmt>`
388 :ref:`V4L2_MPEG_STREAM_VBI_FMT_NONE <v4l2-mpeg-stream-vbi-fmt>`,
389 then the device cannot embed sliced VBI data in the MPEG stream.
392 :ref:`V4L2_CID_MPEG_STREAM_VBI_FMT <v4l2-mpeg-stream-vbi-fmt>`
394 capturing sliced VBI data. The control only indicates to embed sliced
395 VBI data in the MPEG stream, if an application has negotiated sliced VBI
398 It may also be the case that a device can embed sliced VBI data in only
399 certain types of MPEG streams: for example in an MPEG-2 PS but not an
400 MPEG-2 TS. In this situation, if sliced VBI data insertion is requested,
401 the sliced VBI data will be embedded in MPEG stream types when
403 data insertion is not supported by the device.
406 data.
409 MPEG Stream Embedded, Sliced VBI Data Format: NONE
410 --------------------------------------------------
413 :ref:`V4L2_MPEG_STREAM_VBI_FMT_NONE <v4l2-mpeg-stream-vbi-fmt>`
415 to cease embedding sliced VBI data in MPEG streams. Neither the device
416 nor driver shall insert "empty" embedded sliced VBI data packets in the
417 MPEG stream when this format is set. No MPEG stream data structures are
421 MPEG Stream Embedded, Sliced VBI Data Format: IVTV
422 --------------------------------------------------
425 :ref:`V4L2_MPEG_STREAM_VBI_FMT_IVTV <v4l2-mpeg-stream-vbi-fmt>`
427 embed up to 36 lines of sliced VBI data per frame in an MPEG-2 *Private
428 Stream 1 PES* packet encapsulated in an MPEG-2 *Program Pack* in the
432 custom, embedded, sliced VBI data format used by the ``ivtv`` driver.
434 in the file ``Documentation/media/v4l-drivers/cx2341x.rst`` . The
437 to extracting, decoding, and displaying sliced VBI data embedded within
441 exclusive to CX2341x devices, as the sliced VBI data packet insertion
443 ``cx18`` driver provides sliced VBI data insertion into an MPEG-2 PS in
446 The following definitions specify the payload of the MPEG-2 *Private
447 Stream 1 PES* packets that contain sliced VBI data when
448 :ref:`V4L2_MPEG_STREAM_VBI_FMT_IVTV <v4l2-mpeg-stream-vbi-fmt>`
449 is set. (The MPEG-2 *Private Stream 1 PES* packet header and
450 encapsulating MPEG-2 *Program Pack* header are not detailed here. Please
451 refer to the MPEG-2 specifications for details on those packet headers.)
453 The payload of the MPEG-2 *Private Stream 1 PES* packets that contain
454 sliced VBI data is specified by struct
456 payload is variable length, depending on the actual number of lines of
457 sliced VBI data present in a video frame. The payload may be padded at
459 4-byte boundary. The payload shall never exceed 1552 bytes (2 fields
460 with 18 lines/field with 43 bytes of data/line and a 4 byte magic
467 -----------------------------
471 .. flat-table::
472 :header-rows: 0
473 :stub-columns: 0
476 * - __u8
477 - ``magic``\ [4]
478 -
479 - A "magic" constant from :ref:`v4l2-mpeg-vbi-fmt-ivtv-magic` that
480 indicates this is a valid sliced VBI data payload and also
482 ``ITV0``, to use for the payload data.
483 * - union
484 - (anonymous)
485 * -
486 - struct :c:type:`v4l2_mpeg_vbi_itv0`
487 - ``itv0``
488 - The primary form of the sliced VBI data payload that contains
489 anywhere from 1 to 35 lines of sliced VBI data. Line masks are
490 provided in this form of the payload indicating which VBI lines
492 * -
493 - struct :ref:`v4l2_mpeg_vbi_ITV0 <v4l2-mpeg-vbi-itv0-1>`
494 - ``ITV0``
495 - An alternate form of the sliced VBI data payload used when 36
496 lines of sliced VBI data are present. No line masks are provided
502 .. _v4l2-mpeg-vbi-fmt-ivtv-magic:
505 -------------------------------------------------------------
509 .. flat-table::
510 :header-rows: 1
511 :stub-columns: 0
514 * - Defined Symbol
515 - Value
516 - Description
517 * - ``V4L2_MPEG_VBI_IVTV_MAGIC0``
518 - "itv0"
519 - Indicates the ``itv0`` member of the union in struct
522 * - ``V4L2_MPEG_VBI_IVTV_MAGIC1``
523 - "ITV0"
524 - Indicates the ``ITV0`` member of the union in struct
526 valid and that 36 lines of sliced VBI data are present.
535 -------------------------------------------------
539 .. flat-table::
540 :header-rows: 0
541 :stub-columns: 0
544 * - __le32
545 - ``linemask``\ [2]
546 - Bitmasks indicating the VBI service lines present. These
563 linemask[1] b4-b31: unused and set to 0
564 * - struct
566 - ``line``\ [35]
567 - This is a variable length array that holds from 1 to 35 lines of
568 sliced VBI data. The sliced VBI data lines present correspond to
576 one line of unspecified data that should be ignored by
581 .. _v4l2-mpeg-vbi-itv0-1:
584 -------------------------
588 .. flat-table::
589 :header-rows: 0
590 :stub-columns: 0
593 * - struct
595 - ``line``\ [36]
596 - A fixed length array of 36 lines of sliced VBI data. ``line``\ [0]
597 through ``line``\ [17] correspond to lines 6 through 23 of the
599 lines 6 through 23 of the second field.
606 ------------------------------
610 .. flat-table::
611 :header-rows: 0
612 :stub-columns: 0
615 * - __u8
616 - ``id``
617 - A line identifier value from
618 :ref:`ITV0-Line-Identifier-Constants` that indicates the type of
619 sliced VBI data stored on this line.
620 * - __u8
621 - ``data``\ [42]
622 - The sliced VBI data for the line.
626 .. _ITV0-Line-Identifier-Constants:
629 ------------------------------------------------------------
633 .. flat-table::
634 :header-rows: 1
635 :stub-columns: 0
638 * - Defined Symbol
639 - Value
640 - Description
641 * - ``V4L2_MPEG_VBI_IVTV_TELETEXT_B``
642 - 1
643 - Refer to :ref:`Sliced VBI services <vbi-services2>` for a
645 * - ``V4L2_MPEG_VBI_IVTV_CAPTION_525``
646 - 4
647 - Refer to :ref:`Sliced VBI services <vbi-services2>` for a
649 * - ``V4L2_MPEG_VBI_IVTV_WSS_625``
650 - 5
651 - Refer to :ref:`Sliced VBI services <vbi-services2>` for a
653 * - ``V4L2_MPEG_VBI_IVTV_VPS``
654 - 7
655 - Refer to :ref:`Sliced VBI services <vbi-services2>` for a
661 According to :ref:`ETS 300 706 <ets300706>` lines 6-22 of the first
662 field and lines 5-22 of the second field may carry Teletext data.
665 See also :ref:`vbi-525` and :ref:`vbi-625`.