source: svn/branches/kctv/newcon3bcm2_21bu/magnum/commonutils/avc/7552/bavc_vbi.h

Last change on this file was 2, checked in by phkim, 11 years ago

1.phkim

  1. revision copy newcon3sk r27
  • Property svn:executable set to *
File size: 6.2 KB
Line 
1/***************************************************************************
2 *     Copyright (c) 2003-2011, Broadcom Corporation
3 *     All Rights Reserved
4 *     Confidential Property of Broadcom Corporation
5 *
6 *  THIS SOFTWARE MAY ONLY BE USED SUBJECT TO AN EXECUTED SOFTWARE LICENSE
7 *  AGREEMENT  BETWEEN THE USER AND BROADCOM.  YOU HAVE NO RIGHT TO USE OR
8 *  EXPLOIT THIS MATERIAL EXCEPT SUBJECT TO THE TERMS OF SUCH AN AGREEMENT.
9 *
10 * $brcm_Workfile: bavc_vbi.h $
11 * $brcm_Revision: Hydra_Software_Devel/3 $
12 * $brcm_Date: 1/10/11 4:02p $
13 *
14 * Module Description:
15 *
16 * Revision History:
17 *
18 * $brcm_Log: /magnum/commonutils/avc/7422/bavc_vbi.h $
19 *
20 * Hydra_Software_Devel/3   1/10/11 4:02p darnstein
21 * SW7422-46: Increase storage space for multi-line closed caption.
22 * Chipsets 7422 and later can use this.
23 *
24 * Hydra_Software_Devel/2   1/21/10 3:15p darnstein
25 * SW35230-16: these VBI data structures have been approved by the new DTV
26 * team.
27 *
28 * Hydra_Software_Devel/1   11/24/09 5:40p darnstein
29 * SW35230-16: Data structures common to BVBI and DTV reference software.
30 *
31 ***************************************************************************/
32
33#ifndef BAVC_VBI_H__
34#define BAVC_VBI_H__
35
36#ifdef __cplusplus
37extern "C" {
38#endif
39
40/*=Module Overview: ********************************************************
41The purpose of this common utility is to express VBI related data
42structures that are shared between the BVBI porting interface module,
43and the newer DTV software. This utility does not contain any functions.
44
45These data structures define the storage of VBI data such as closed
46caption and teletext.
47
48****************************************************************************/
49
50/*
51 * Data structures
52 */ 
53
54/*****************************************************************************
55  Summary:
56    Structure for holding teletext data
57   
58  Description:
59    The BAVC_VBI_TT_Line structure is a container for a single line of
60        teletext data.
61 *****************************************************************************/
62#define BAVC_VBI_TT_MAX_LINESIZE 42
63typedef struct BAVC_VBI_TT_Line
64{
65        uint8_t ucFramingCode;
66        uint8_t aucData[BAVC_VBI_TT_MAX_LINESIZE];
67}
68BAVC_VBI_TT_Line;
69
70/*****************************************************************************
71  Summary:
72    Structure for holding Gemstar data
73   
74  Description:
75    The BAVC_VBI_GSData structure is a container for an entire field of Gemstar
76        data. Note that when sending this data to the Gemstar encoder hardware,
77        there are two conditions to observe:
78        1. If the ulErrorLines field is non-zero, then the data will not be
79           encoded. This is an error condition.
80    2. If the Gemstar encoder hardware has been programmed in such a way that
81           some of the data cannot be encoded, then none of it will be encoded.
82           This is an error condition.
83 *****************************************************************************/
84#define BAVC_VBI_GS_MAX_LINES 5
85typedef struct BAVC_VBI_GSData
86{
87        uint32_t ulDataLines;  /* A bitmask indicating the significance of the
88                                  following field ulData. If the ith "one" bit
89                                                          in ulDataLines is in position j, then entry i
90                                                          of ulData contains Gemstar data for video
91                                                          line j.  For bottom field, add 263 to j. Note
92                                                          that the lowest and higest several bits  of
93                                                          this field should always be low.               */
94        uint32_t ulErrorLines; /* A bitmask indicating which entries of the
95                                  following array ulData have errors.
96                                                          Typically, these would be parity errors
97                                                          reported by the Gemstar decoder hardware.
98                                                          The  ith bit in ulErrorLines refers to the
99                                                          ith entry in ulData. There is no
100                                                          relationship with ulDataLines.                 */
101        uint32_t ulData[BAVC_VBI_GS_MAX_LINES];
102                               /* Each entry contains Gemstar data from one
103                                                          video line in the VBI. Some of this data
104                                                          may be in error. The valid data can be
105                                                          located by ANDing ulDataLines with the ones'
106                                                          complement of ulErrorLines.                    */
107
108} BAVC_VBI_GSData;
109
110/*****************************************************************************
111  Summary:
112    Structure for holding multi-line closed caption data
113   
114  Description:
115    The BAVC_VBI_MCCData structure is a container for an entire field of
116        multi-line closed caption data.
117 *****************************************************************************/
118typedef struct BAVC_VBI_MCCData
119{
120        uint16_t uhLineMask;      /* Bitmask indicating which video lines will
121                                     (eventually) receive MCC data.  For any top
122                                                                 field, the LSB refers to video line 8. For
123                                                                 NTSC bottom field, the LSB refers to line
124                                                                 271. For PAL bottom field, the LSB refers to
125                                                                 line 321.  Due to hardware constraints, the
126                                                                 number of bits in this value that may be set
127                                                                 to 1 varies by chipset.                     */
128        uint8_t  ucData[32];      /* 32 bytes dataL0, dataH0, ... dataL16,
129                                     dataH16. DataL0 and dataH0 are the low byte
130                                                                 and high byte (respectively) to be sent to
131                                                                 the first video line indicated by the above
132                                                                 bitmask.  DataL16 and dataH16 will be sent to
133                                                                 the sixth video line indicated (if
134                                                                 indicated) by the above bitmask.            */
135
136} BAVC_VBI_MCCData;
137
138
139/*****************************************************************************
140  Summary:
141    Structure for holding CGMS-B data
142   
143  Description:
144    The BAVC_VBI_CGMSB_Datum structure is a container for a single line of
145        CGMS-B data.
146 *****************************************************************************/
147typedef uint32_t BAVC_VBI_CGMSB_Datum[5];
148
149
150/*****************************************************************************
151  Summary:
152    Structure for one field's VPS data
153
154  Description:
155    BAVC_VBI_VPSData is a holder for the 6 bytes of VPS data that can
156        be processed in one video field.
157 *****************************************************************************/
158typedef struct 
159{
160        uint8_t  ucByte05;
161        uint8_t  ucByte11;
162        uint8_t  ucByte12;
163        uint8_t  ucByte13;
164        uint8_t  ucByte14;
165        uint8_t  ucByte15;
166
167} BAVC_VBI_VPSData;
168
169#ifdef __cplusplus
170}
171#endif
172
173#endif /* #ifndef BAVC_VBI_H__ */
174
175/* end of file */
Note: See TracBrowser for help on using the repository browser.