]> git.vomp.tv Git - vompclient-marten.git/blob - stb.h
Initial import
[vompclient-marten.git] / stb.h
1 /*
2
3     This file is modified by Chris Tallon from the original stb.h
4     in libav, from the mvpmc project. libav is licensed under the
5     Lesser General Public License.
6
7     As per point 3 of the Lesser General Public License, I am
8     applying the General Public License to my copy of the library
9     and therefore to this file. The copyright notice below has been
10     changed accordingly.
11
12 */
13
14 /*
15     Copyright (C) 2004, BtB, Jon Gettler
16     http://mvpmc.sourceforge.net/
17
18     This file is free software; you can redistribute it and/or modify
19     it under the terms of the GNU General Public License as published by
20     the Free Software Foundation; either version 2 of the License, or
21     (at your option) any later version.
22
23     This file is distributed in the hope that it will be useful,
24     but WITHOUT ANY WARRANTY; without even the implied warranty of
25     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
26     GNU General Public License for more details.
27
28     You should have received a copy of the GNU General Public License
29     along with This file; if not, write to the Free Software
30     Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
31
32  */
33
34
35 #ifndef STB_H
36 #define STB_H
37
38 /*
39  * $Id$
40  *
41  * This describes the IBM STBx25xx/STBx30xxx hardware interface.
42  *
43  * Jon Gettler <gettler@acm.org>
44  */
45
46 #include <stdint.h>
47
48 typedef struct {
49   int arg;
50   int a;
51   int b;
52   int c;
53   int d;
54   int e;
55   int f;
56 } set_display_t;
57
58
59
60 typedef struct {
61   unsigned long handle1;
62   unsigned long x;
63   unsigned long y;
64   unsigned long w;
65   unsigned long h;
66   unsigned long handle2;
67   unsigned long x1;
68   unsigned long y1;
69   unsigned long w1;
70   unsigned long h1;
71   unsigned long colour1;
72 } osd_blend_t;
73
74 typedef struct {
75   unsigned long handle;
76   unsigned long x;
77   unsigned long y;
78   unsigned long w;
79   unsigned long h;
80   unsigned long colour1;
81   unsigned long colour2;
82   unsigned long colour3;
83   unsigned long colour4;
84   unsigned long colour5;
85   unsigned long colour6;
86   unsigned long colour7;
87   unsigned char c[2];
88 } osd_afillblt_t;
89
90 typedef struct {
91   unsigned long handle;
92   unsigned long left;
93   unsigned long top;
94   unsigned long right;
95   unsigned long bottom;
96 } osd_clip_rec_t;
97
98 typedef struct {
99   int w;
100   int h;
101   int scale;
102   int x1;
103   int y;
104   int x;
105   int y2;
106   int x3;
107   int y3;
108   int x4;
109   int y4;
110 } vid_pos_regs_t;
111
112 typedef struct {
113   int stc_b32;
114   int stc_b0;
115   int pts_b32;
116   int pts_b0;
117 } pts_sync_data_t;
118
119 typedef struct {
120   int parm1;
121   int parm2;
122 } aud_sync_parms_t;
123
124 typedef struct {
125   int aud_ctl0;
126   int aud_ctl1;
127   int aud_ctl2;
128 } aud_ctl_regs_t;
129
130 typedef struct {
131   int denc0_cr1;
132   int denc1_cr1;
133   int dencmux;
134   int vid_disp_mode;
135 } vid_ctl_regs_t;
136
137 struct vid_regs {
138   unsigned char dummy[44];
139 };
140
141 typedef struct {
142   int nleft;
143   int state;
144 } vid_state_regs_t;
145
146 typedef struct {
147   uint64_t stc;
148   uint64_t pts;
149 } sync_data_t;
150
151
152 /*
153  * /dev/adec_mpeg
154  */
155 #define AV_SET_AUD_PLAY   _IOW('a',2,int)
156 #define AV_SET_AUD_PAUSE  _IOW('a',3,int)
157 #define AV_SET_AUD_UNPAUSE  _IOW('a',4,int)
158 #define AV_SET_AUD_SRC    _IOW('a',5,int)
159 #define AV_SET_AUD_MUTE   _IOW('a',6,int)
160 #define AV_SET_AUD_CHANNEL  _IOW('a',9,int)
161 #define AV_GET_AUD_INFO   _IOR('a',10,int)
162 #define AV_SET_AUD_VOLUME _IOW('a',13,int)
163 #define AV_GET_AUD_VOLUME _IOR('a',14,int)
164 #define AV_SET_AUD_STREAMTYPE _IOW('a',15,int)
165 #define AV_SET_AUD_FORMAT _IOW('a',16,int)
166 #define AV_GET_AUD_SYNC   _IOR('a',21,pts_sync_data_t*)
167 #define AV_SET_AUD_STC    _IOW('a',22,uint64_t *)
168 #define AV_SET_AUD_SYNC   _IOW('a',23,int)
169 #define AV_SET_AUD_DISABLE_SYNC _IOW('a',24,aud_sync_parms_t*)
170 #define AV_SET_AUD_RESET  _IOW('a',26,int)
171 #define AV_SET_AUD_DAC_CLK  _IOW('a',27,int)
172 #define AV_GET_AUD_REGS   _IOW('a',28,aud_ctl_regs_t*)
173
174 /*
175  * /dev/vdec_dev
176  */
177
178 // CJT
179 #define AV_SET_VID_STOP    _IOW('v', 21, int)
180
181
182 #define AV_SET_VID_PLAY   _IOW('v',22,int)
183 #define AV_SET_VID_FREEZE _IOW('v',23,int)
184 #define AV_SET_VID_RESUME _IOW('v',24,int)
185 #define AV_SET_VID_SRC    _IOW('v',25,int)
186 #define AV_SET_VID_FB   _IOW('v',26,int)
187 #define AV_GET_VID_STATE  _IOR('v',27,vid_state_regs_t*)
188 #define AV_SET_VID_PAUSE  _IOW('v',28,int)
189 #define AV_SET_VID_FFWD   _IOW('v',29,int)
190 #define AV_SET_VID_SLOMO  _IOW('v',30,int)
191 #define AV_SET_VID_BLANK  _IOW('v',32,int)
192 #define AV_SET_VID_POSITION _IOW('v',36,vid_pos_regs_t*)
193 #define AV_SET_VID_SCALE_ON _IOW('v',37,int)
194 #define AV_SET_VID_SCALE_OFF  _IOW('v',38,int)
195 #define AV_GET_VID_SYNC   _IOR('v',39,int)
196 #define AV_SET_VID_STC    _IOW('v',40,uint64_t *)
197 #define AV_SET_VID_RATIO  _IOW('v',41,int)
198 #define AV_SET_VID_SYNC   _IOW('v',42,int)
199 #define AV_SET_VID_DISABLE_SYNC _IOW('v',43,int)
200 #define AV_SET_VID_DISP_FMT _IOW('v',45,int)
201 #define AV_SET_VID_RESET  _IOW('v',51,int)
202 #define AV_SET_VID_OUTPUT _IOW('v',57,int)
203 #define AV_SET_VID_MODE   _IOW('v',58,int)
204 #define AV_GET_VID_REGS   _IOR('v',61,struct vid_regs*)
205 #define AV_SET_VID_COLORBAR _IOW('v',62,int)
206 #define AV_SET_VID_DENC   _IOW('v',63,int)
207 #define AV_CHK_SCART    _IOW('v',64,int)
208
209 /*
210  * screen device
211  */
212 #define AV_GET_VID_INFO   _IOR('s',44,int)
213
214 /*
215  * /dev/rawir
216  */
217 #define IR_SET_LED    _IOW('i',21,int)
218
219
220 #endif /* STB_H */