summaryrefslogtreecommitdiffstats
path: root/uisimulator/sdl/uisdl.h
blob: 49556a99fe06d2f582b3543dcacbd130901dc230 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
/***************************************************************************
 *             __________               __   ___.
 *   Open      \______   \ ____   ____ |  | _\_ |__   _______  ___
 *   Source     |       _//  _ \_/ ___\|  |/ /| __ \ /  _ \  \/  /
 *   Jukebox    |    |   (  <_> )  \___|    < | \_\ (  <_> > <  <
 *   Firmware   |____|_  /\____/ \___  >__|_ \|___  /\____/__/\_ \
 *                     \/            \/     \/    \/            \/
 * $Id$
 *
 * Copyright (C) 2006 Dan Everton
 *
 * All files in this archive are subject to the GNU General Public License.
 * See the file COPYING in the source tree root for full license agreement.
 *
 * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY
 * KIND, either express or implied.
 *
 ****************************************************************************/

#ifndef __UISDL_H__
#define __UISDL_H__

#include <stdbool.h>
#include "SDL.h"

/* colour definitions are R, G, B */

#if defined(ARCHOS_RECORDER)
#define UI_TITLE                    "Jukebox Recorder"
#define UI_WIDTH                    270 /* width of GUI window */
#define UI_HEIGHT                   406 /* height of GUI window */
#define UI_LCD_BGCOLOR              90, 145, 90 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         126, 229, 126 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 80 /* x position of lcd */
#define UI_LCD_POSY                 104 /* y position of lcd (96 for real aspect) */
#define UI_LCD_WIDTH                112
#define UI_LCD_HEIGHT               64 /* (80 for real aspect) */

#elif defined(ARCHOS_PLAYER)
#define UI_TITLE                    "Jukebox Player"
#define UI_WIDTH                    284 /* width of GUI window */
#define UI_HEIGHT                   420 /* height of GUI window */
#define UI_LCD_BGCOLOR              90, 145, 90 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         126, 229, 126 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 75 /* x position of lcd */
#define UI_LCD_POSY                 116 /* y position of lcd */
#define UI_LCD_WIDTH                132
#define UI_LCD_HEIGHT               64

#elif defined(ARCHOS_FMRECORDER) || defined(ARCHOS_RECORDERV2)
#define UI_TITLE                    "Jukebox FM Recorder"
#define UI_WIDTH                    285 /* width of GUI window */
#define UI_HEIGHT                   414 /* height of GUI window */
#define UI_LCD_BGCOLOR              90, 145, 90 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         126, 229, 126 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 87 /* x position of lcd */
#define UI_LCD_POSY                 77 /* y position of lcd (69 for real aspect) */
#define UI_LCD_WIDTH                112
#define UI_LCD_HEIGHT               64 /* (80 for real aspect) */

#elif defined(ARCHOS_ONDIOSP) || defined(ARCHOS_ONDIOFM)
#define UI_TITLE                    "Ondio"
#define UI_WIDTH                    155 /* width of GUI window */
#define UI_HEIGHT                   334 /* height of GUI window */
#define UI_LCD_BGCOLOR              90, 145, 90 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         130, 180, 250 /* bkgnd color of LCD (backlight mod) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 21 /* x position of lcd */
#define UI_LCD_POSY                 82 /* y position of lcd (74 for real aspect) */
#define UI_LCD_WIDTH                112
#define UI_LCD_HEIGHT               64 /* (80 for real aspect) */

#elif defined(IRIVER_H120) || defined(IRIVER_H100)
#define UI_TITLE                    "iriver H1x0"
#define UI_WIDTH                    379 /* width of GUI window */
#define UI_HEIGHT                   508 /* height of GUI window */
#define UI_LCD_BGCOLOR              90, 145, 90 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         173, 216, 230 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 109 /* x position of lcd */
#define UI_LCD_POSY                 23 /* y position of lcd */
#define UI_LCD_WIDTH                160
#define UI_LCD_HEIGHT               128
#define UI_REMOTE_BGCOLOR           90, 145, 90 /* bkgnd of remote lcd (no bklight) */
#define UI_REMOTE_BGCOLORLIGHT      130, 180, 250 /* bkgnd of remote lcd (bklight) */
#define UI_REMOTE_POSX              50  /* x position of remote lcd */
#define UI_REMOTE_POSY              403 /* y position of remote lcd */
#define UI_REMOTE_WIDTH             128
#define UI_REMOTE_HEIGHT            64

#elif defined(IRIVER_H300)
#define UI_TITLE                    "iriver H300"
#define UI_WIDTH                    288 /* width of GUI window */
#define UI_HEIGHT                   581 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 26 /* x position of lcd */
#define UI_LCD_POSY                 36 /* y position of lcd */
#define UI_LCD_WIDTH                220
#define UI_LCD_HEIGHT               176
#define UI_REMOTE_BGCOLOR           90, 145, 90 /* bkgnd of remote lcd (no bklight) */
#define UI_REMOTE_BGCOLORLIGHT      130, 180, 250 /* bkgnd of remote lcd (bklight) */
#define UI_REMOTE_POSX              12  /* x position of remote lcd */
#define UI_REMOTE_POSY              478 /* y position of remote lcd */
#define UI_REMOTE_WIDTH             128
#define UI_REMOTE_HEIGHT            64

#elif defined(IPOD_1G2G)
#define UI_TITLE                    "iPod 1G/2G"
#define UI_WIDTH                    224 /* width of GUI window */
#define UI_HEIGHT                   382 /* height of GUI window */
#define UI_LCD_BGCOLOR              100, 135, 100 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         223, 216, 255 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 32 /* x position of lcd */
#define UI_LCD_POSY                 12 /* y position of lcd */
#define UI_LCD_WIDTH                160
#define UI_LCD_HEIGHT               128

#elif defined(IPOD_3G)
#define UI_TITLE                    "iPod 3G"
#define UI_WIDTH                    218 /* width of GUI window */
#define UI_HEIGHT                   389 /* height of GUI window */
#define UI_LCD_BGCOLOR              90, 145, 90 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         173, 216, 230 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 29 /* x position of lcd */
#define UI_LCD_POSY                 16 /* y position of lcd */
#define UI_LCD_WIDTH                160
#define UI_LCD_HEIGHT               128

#elif defined(IPOD_4G)
#define UI_TITLE                    "iPod 4G"
#define UI_WIDTH                    196 /* width of GUI window */
#define UI_HEIGHT                   370 /* height of GUI window */
#define UI_LCD_BGCOLOR              90, 145, 90 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         173, 216, 230 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 19 /* x position of lcd */
#define UI_LCD_POSY                 14 /* y position of lcd */
#define UI_LCD_WIDTH                160
#define UI_LCD_HEIGHT               128

#elif defined(IPOD_MINI) || defined(IPOD_MINI2G)
#define UI_TITLE                    "iPod mini"
#define UI_WIDTH                    191 /* width of GUI window */
#define UI_HEIGHT                   365 /* height of GUI window */
#define UI_LCD_BGCOLOR              100, 135, 100 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         223, 216, 255 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 24 /* x position of lcd */
#define UI_LCD_POSY                 17 /* y position of lcd */
#define UI_LCD_WIDTH                138
#define UI_LCD_HEIGHT               110

#elif defined(IPOD_COLOR)
#define UI_TITLE                    "iPod Color"
#define UI_WIDTH                    261 /* width of GUI window */
#define UI_HEIGHT                   493 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 21 /* x position of lcd */
#define UI_LCD_POSY                 16 /* y position of lcd */
#define UI_LCD_WIDTH                220
#define UI_LCD_HEIGHT               176

#elif defined(IPOD_NANO)
#define UI_TITLE                    "iPod Nano"
#define UI_WIDTH                    199 /* width of GUI window */
#define UI_HEIGHT                   421 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 13 /* x position of lcd */
#define UI_LCD_POSY                 14 /* y position of lcd */
#define UI_LCD_WIDTH                176
#define UI_LCD_HEIGHT               132

#elif defined(IPOD_VIDEO)
#define UI_TITLE                    "iPod Video"
#define UI_WIDTH                    350 /* width of GUI window */
#define UI_HEIGHT                   591 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 14 /* x position of lcd */
#define UI_LCD_POSY                 12 /* y position of lcd */
#define UI_LCD_WIDTH                320
#define UI_LCD_HEIGHT               240

#elif defined(IAUDIO_X5)
#define UI_TITLE                    "iAudio X5"
#define UI_WIDTH                    300 /* width of GUI window */
#define UI_HEIGHT                   558 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 55 /* x position of lcd */
#define UI_LCD_POSY                 61 /* y position of lcd (74 for real aspect) */
#define UI_LCD_WIDTH                LCD_WIDTH /* * 1.5 */
#define UI_LCD_HEIGHT               LCD_HEIGHT  /* * 1.5 */
#define UI_REMOTE_BGCOLOR           90, 145, 90 /* bkgnd of remote lcd (no bklight) */
#define UI_REMOTE_BGCOLORLIGHT      130, 180, 250 /* bkgnd of remote lcd (bklight) */
#define UI_REMOTE_POSX              12  /* x position of remote lcd */
#define UI_REMOTE_POSY              462 /* y position of remote lcd */
#define UI_REMOTE_WIDTH             128
#define UI_REMOTE_HEIGHT            96

#elif defined(IAUDIO_M5)
#define UI_TITLE                    "iAudio M5"
#define UI_WIDTH                    374 /* width of GUI window */
#define UI_HEIGHT                   650 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 82 /* x position of lcd */
#define UI_LCD_POSY                 74 /* y position of lcd (74 for real aspect) */
#define UI_LCD_BGCOLOR              100, 135, 100 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         223, 216, 255 /* bkgnd color of LCD (backlight) */
#define UI_LCD_WIDTH                LCD_WIDTH /* * 1.5 */
#define UI_LCD_HEIGHT               LCD_HEIGHT  /* * 1.5 */
#define UI_REMOTE_BGCOLOR           90, 145, 90 /* bkgnd of remote lcd (no bklight) */
#define UI_REMOTE_BGCOLORLIGHT      130, 180, 250 /* bkgnd of remote lcd (bklight) */
#define UI_REMOTE_POSX              59  /* x position of remote lcd */
#define UI_REMOTE_POSY              509 /* y position of remote lcd */
#define UI_REMOTE_WIDTH             128
#define UI_REMOTE_HEIGHT            96

#elif defined(GIGABEAT_F)
#define UI_TITLE                    "Toshiba Gigabeat"
#define UI_WIDTH                    401 /* width of GUI window */
#define UI_HEIGHT                   655 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 48 /* x position of lcd */
#define UI_LCD_POSY                 60 /* y position of lcd */
#define UI_LCD_WIDTH                240
#define UI_LCD_HEIGHT               320

#elif defined(MROBE_500)
#define UI_TITLE                    "Olympus M:Robe 500"
#define UI_WIDTH                    401 /* width of GUI window */
#define UI_HEIGHT                   655 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 48 /* x position of lcd */
#define UI_LCD_POSY                 60 /* y position of lcd */
#define UI_LCD_WIDTH                LCD_WIDTH
#define UI_LCD_HEIGHT               LCD_HEIGHT
#define UI_REMOTE_BGCOLOR           90, 145, 90 /* bkgnd of remote lcd (no bklight) */
#define UI_REMOTE_BGCOLORLIGHT      130, 180, 250 /* bkgnd of remote lcd (bklight) */
#define UI_REMOTE_POSX              50  /* x position of remote lcd */
#define UI_REMOTE_POSY              403 /* y position of remote lcd */
#define UI_REMOTE_WIDTH             79
#define UI_REMOTE_HEIGHT            16

#elif defined(IRIVER_H10)
#define UI_TITLE                    "iriver H10 20Gb"
#define UI_WIDTH                    392 /* width of GUI window */
#define UI_HEIGHT                   391 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 111 /* x position of lcd */
#define UI_LCD_POSY                 30 /* y position of lcd (74 for real aspect) */
#define UI_LCD_WIDTH                LCD_WIDTH /* * 1.5 */
#define UI_LCD_HEIGHT               LCD_HEIGHT  /* * 1.5 */

#elif defined(IRIVER_H10_5GB)
#define UI_TITLE                    "iriver H10 5/6Gb"
#define UI_WIDTH                    353 /* width of GUI window */
#define UI_HEIGHT                   460 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 112 /* x position of lcd */
#define UI_LCD_POSY                 45  /* y position of lcd (74 for real aspect) */
#define UI_LCD_WIDTH                LCD_WIDTH /* * 1.5 */
#define UI_LCD_HEIGHT               LCD_HEIGHT  /* * 1.5 */

#elif defined(SANSA_E200)
#define UI_TITLE                    "Sansa e200"
#define UI_WIDTH                    260 /* width of GUI window */
#define UI_HEIGHT                   502 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 42 /* x position of lcd */
#define UI_LCD_POSY                 37  /* y position of lcd (74 for real aspect) */
#define UI_LCD_WIDTH                LCD_WIDTH /* * 1.5 */
#define UI_LCD_HEIGHT               LCD_HEIGHT  /* * 1.5 */

#elif defined(SANSA_C200)
#define UI_TITLE                    "Sansa c200"
#define UI_WIDTH                    350 /* width of GUI window */
#define UI_HEIGHT                   152 /* height of GUI window */
/* high-colour */
#define UI_LCD_POSX                 42 /* x position of lcd */
#define UI_LCD_POSY                 35  /* y position of lcd (74 for real aspect) */
#define UI_LCD_WIDTH                LCD_WIDTH /* * 1.5 */
#define UI_LCD_HEIGHT               LCD_HEIGHT  /* * 1.5 */

#elif defined(IRIVER_IFP7XX)
#define UI_TITLE                    "iriver iFP7xx"
#define UI_WIDTH                    425 /* width of GUI window */
#define UI_HEIGHT                   183 /* height of GUI window */
#define UI_LCD_BGCOLOR              94, 104, 84 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         60, 160, 230 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 115 /* x position of lcd */
#define UI_LCD_POSY                 54 /* y position of lcd */
#define UI_LCD_WIDTH                LCD_WIDTH /* * 1.5 */
#define UI_LCD_HEIGHT               LCD_HEIGHT  /* * 1.5 */
    
#elif defined(ARCHOS_AV300)
#define UI_TITLE                    "Archos AV300"
/* We are temporarily using a 2bpp LCD driver and dummy bitmap */
#define UI_WIDTH                    420 /* width of GUI window */
#define UI_HEIGHT                   340 /* height of GUI window */
#define UI_LCD_POSX                 50 /* x position of lcd */
#define UI_LCD_POSY                 50 /* y position of lcd */
#define UI_LCD_WIDTH                320
#define UI_LCD_HEIGHT               240
#define UI_LCD_BGCOLOR              90, 145, 90 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         173, 216, 230 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */

#elif defined(MROBE_100)
#define UI_TITLE                    "Olympus M:Robe 100"
#define UI_WIDTH                    247 /* width of GUI window */
#define UI_HEIGHT                   416 /* height of GUI window */
#define UI_LCD_BGCOLOR              94, 2, 2 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         241, 6, 3 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */
#define UI_LCD_POSX                 43 /* x position of lcd */
#define UI_LCD_POSY                 25 /* y position of lcd */
#define UI_LCD_WIDTH                160
#define UI_LCD_HEIGHT               128

#elif defined(COWON_D2)
#define UI_TITLE                    "Cowon D2"
#define UI_WIDTH                    420 /* width of GUI window */
#define UI_HEIGHT                   340 /* height of GUI window */
#define UI_LCD_POSX                 50 /* x position of lcd */
#define UI_LCD_POSY                 50 /* y position of lcd */
#define UI_LCD_WIDTH                320
#define UI_LCD_HEIGHT               240
#define UI_LCD_BGCOLOR              32, 32, 32 /* bkgnd color of LCD (no backlight) */
#define UI_LCD_BGCOLORLIGHT         192, 192, 192 /* bkgnd color of LCD (backlight) */
#define UI_LCD_BLACK                0, 0, 0 /* black */

#endif
extern SDL_Surface *gui_surface;
extern bool background;  /* True if the background image is enabled */
extern int display_zoom; 

#endif /* #ifndef __UISDL_H__ */