author | KUDr |
Tue, 06 Mar 2007 20:18:17 +0000 | |
branch | cpp_gui |
changeset 6292 | 272c690043e3 |
parent 6285 | 187e3ef04cc9 |
child 6298 | c30fe89622df |
child 6573 | 7624f942237f |
permissions | -rw-r--r-- |
2186 | 1 |
/* $Id$ */ |
2 |
||
6285
187e3ef04cc9
(svn r9004) [cpp_gui] -Sync with trunk (r8900..r9003)
KUDr
parents:
6192
diff
changeset
|
3 |
/** @file hal.h Hardware Abstraction Layer declarations */ |
187e3ef04cc9
(svn r9004) [cpp_gui] -Sync with trunk (r8900..r9003)
KUDr
parents:
6192
diff
changeset
|
4 |
|
0 | 5 |
#ifndef HAL_H |
6 |
#define HAL_H |
|
7 |
||
8 |
typedef struct { |
|
1301
313804601383
(svn r1805) Teach the driver layer a few things about const correctness
tron
parents:
1093
diff
changeset
|
9 |
const char *(*start)(const char * const *parm); |
1093
e8d26c7dc42f
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
10 |
void (*stop)(void); |
0 | 11 |
} HalCommonDriver; |
12 |
||
13 |
typedef struct { |
|
1301
313804601383
(svn r1805) Teach the driver layer a few things about const correctness
tron
parents:
1093
diff
changeset
|
14 |
const char *(*start)(const char * const *parm); |
1093
e8d26c7dc42f
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
15 |
void (*stop)(void); |
0 | 16 |
void (*make_dirty)(int left, int top, int width, int height); |
2228 | 17 |
void (*main_loop)(void); |
0 | 18 |
bool (*change_resolution)(int w, int h); |
1829
0b6de3b4458a
(svn r2334) - Fix (regression): moved togglefullscreen into the video-driver, now windows works, dedicated works and sdl works. Also reverted the change to the makefile.
Darkvater
parents:
1596
diff
changeset
|
19 |
void (*toggle_fullscreen)(bool fullscreen); |
0 | 20 |
} HalVideoDriver; |
21 |
||
22 |
typedef struct { |
|
1301
313804601383
(svn r1805) Teach the driver layer a few things about const correctness
tron
parents:
1093
diff
changeset
|
23 |
const char *(*start)(const char * const *parm); |
1093
e8d26c7dc42f
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
24 |
void (*stop)(void); |
0 | 25 |
} HalSoundDriver; |
26 |
||
27 |
typedef struct { |
|
1301
313804601383
(svn r1805) Teach the driver layer a few things about const correctness
tron
parents:
1093
diff
changeset
|
28 |
const char *(*start)(const char * const *parm); |
1093
e8d26c7dc42f
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
29 |
void (*stop)(void); |
0 | 30 |
|
31 |
void (*play_song)(const char *filename); |
|
1093
e8d26c7dc42f
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
32 |
void (*stop_song)(void); |
e8d26c7dc42f
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
33 |
bool (*is_song_playing)(void); |
0 | 34 |
void (*set_volume)(byte vol); |
35 |
} HalMusicDriver; |
|
36 |
||
5838
9c3129cb019b
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5726
diff
changeset
|
37 |
extern HalMusicDriver *_music_driver; |
9c3129cb019b
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5726
diff
changeset
|
38 |
extern HalSoundDriver *_sound_driver; |
9c3129cb019b
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5726
diff
changeset
|
39 |
extern HalVideoDriver *_video_driver; |
0 | 40 |
|
41 |
enum DriverType { |
|
42 |
VIDEO_DRIVER = 0, |
|
43 |
SOUND_DRIVER = 1, |
|
44 |
MUSIC_DRIVER = 2, |
|
45 |
}; |
|
46 |
||
47 |
#endif /* HAL_H */ |