diff options
author | Andy Walls <awalls@radix.net> | 2009-03-14 17:06:07 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2009-03-30 12:43:22 -0300 |
commit | 6273fda6e32e2cd9a478545d0cbc15ac497b1f4b (patch) | |
tree | 0b44d28fd3fb2092b332c8372b7325ca18f004ee /include/linux/videodev2.h | |
parent | 77ac0baf24d1a43498f7bdf6efa2ee6c4ed0ebaa (diff) | |
download | blackbird-op-linux-6273fda6e32e2cd9a478545d0cbc15ac497b1f4b.tar.gz blackbird-op-linux-6273fda6e32e2cd9a478545d0cbc15ac497b1f4b.zip |
V4L/DVB (11042): v4l2-api: Add definitions for V4L2_MPEG_STREAM_VBI_FMT_IVTV payloads
This addition to the v4l2-api add definitions for the constants and
data structures used for sliced VBI data insertion into MPEG streams triggered
by V4L2_MPEG_STREAM_VBI_FMT_IVTV. This simply declares what the ivtv and
cx18 drivers and MythTV have already been doing and provides a proper data
structure definition to user space.
Signed-off-by: Andy Walls <awalls@radix.net>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'include/linux/videodev2.h')
-rw-r--r-- | include/linux/videodev2.h | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index 78ba0755ffb3..61f1a4921afd 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h @@ -1348,6 +1348,53 @@ struct v4l2_sliced_vbi_data { }; /* + * Sliced VBI data inserted into MPEG Streams + */ + +/* + * V4L2_MPEG_STREAM_VBI_FMT_IVTV: + * + * Structure of payload contained in an MPEG 2 Private Stream 1 PES Packet in an + * MPEG-2 Program Pack that contains V4L2_MPEG_STREAM_VBI_FMT_IVTV Sliced VBI + * data + * + * Note, the MPEG-2 Program Pack and Private Stream 1 PES packet header + * definitions are not included here. See the MPEG-2 specifications for details + * on these headers. + */ + +/* Line type IDs */ +#define V4L2_MPEG_VBI_IVTV_TELETEXT_B (1) +#define V4L2_MPEG_VBI_IVTV_CAPTION_525 (4) +#define V4L2_MPEG_VBI_IVTV_WSS_625 (5) +#define V4L2_MPEG_VBI_IVTV_VPS (7) + +struct v4l2_mpeg_vbi_itv0_line { + __u8 id; /* One of V4L2_MPEG_VBI_IVTV_* above */ + __u8 data[42]; /* Sliced VBI data for the line */ +} __attribute__ ((packed)); + +struct v4l2_mpeg_vbi_itv0 { + __le32 linemask[2]; /* Bitmasks of VBI service lines present */ + struct v4l2_mpeg_vbi_itv0_line line[35]; +} __attribute__ ((packed)); + +struct v4l2_mpeg_vbi_ITV0 { + struct v4l2_mpeg_vbi_itv0_line line[36]; +} __attribute__ ((packed)); + +#define V4L2_MPEG_VBI_IVTV_MAGIC0 "itv0" +#define V4L2_MPEG_VBI_IVTV_MAGIC1 "ITV0" + +struct v4l2_mpeg_vbi_fmt_ivtv { + __u8 magic[4]; + union { + struct v4l2_mpeg_vbi_itv0 itv0; + struct v4l2_mpeg_vbi_ITV0 ITV0; + }; +} __attribute__ ((packed)); + +/* * A G G R E G A T E S T R U C T U R E S */ |