author | rubidium |
Thu, 01 Feb 2007 15:49:12 +0000 | |
changeset 5893 | 7e431a4abebb |
parent 5636 | 3c19b56dc982 |
child 5941 | adaea39e84ab |
permissions | -rw-r--r-- |
2186 | 1 |
/* $Id$ */ |
2 |
||
0 | 3 |
#ifndef HAL_H |
4 |
#define HAL_H |
|
5 |
||
5587
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
6 |
#ifdef __cplusplus |
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
7 |
extern "C" { |
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
8 |
#endif //__cplusplus |
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
9 |
|
0 | 10 |
typedef struct { |
1301
bf64ba5b6774
(svn r1805) Teach the driver layer a few things about const correctness
tron
parents:
1093
diff
changeset
|
11 |
const char *(*start)(const char * const *parm); |
1093
4fdc46eaf423
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
12 |
void (*stop)(void); |
0 | 13 |
} HalCommonDriver; |
14 |
||
15 |
typedef struct { |
|
1301
bf64ba5b6774
(svn r1805) Teach the driver layer a few things about const correctness
tron
parents:
1093
diff
changeset
|
16 |
const char *(*start)(const char * const *parm); |
1093
4fdc46eaf423
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
17 |
void (*stop)(void); |
0 | 18 |
void (*make_dirty)(int left, int top, int width, int height); |
2228 | 19 |
void (*main_loop)(void); |
0 | 20 |
bool (*change_resolution)(int w, int h); |
1829
e90fe433fa7d
(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
|
21 |
void (*toggle_fullscreen)(bool fullscreen); |
0 | 22 |
} HalVideoDriver; |
23 |
||
24 |
typedef struct { |
|
1301
bf64ba5b6774
(svn r1805) Teach the driver layer a few things about const correctness
tron
parents:
1093
diff
changeset
|
25 |
const char *(*start)(const char * const *parm); |
1093
4fdc46eaf423
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
26 |
void (*stop)(void); |
0 | 27 |
} HalSoundDriver; |
28 |
||
29 |
typedef struct { |
|
1301
bf64ba5b6774
(svn r1805) Teach the driver layer a few things about const correctness
tron
parents:
1093
diff
changeset
|
30 |
const char *(*start)(const char * const *parm); |
1093
4fdc46eaf423
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
31 |
void (*stop)(void); |
0 | 32 |
|
33 |
void (*play_song)(const char *filename); |
|
1093
4fdc46eaf423
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
34 |
void (*stop_song)(void); |
4fdc46eaf423
(svn r1594) Convert all undefined parameter lists to (void) and add the appropriate warning flags in the Makefile
tron
parents:
810
diff
changeset
|
35 |
bool (*is_song_playing)(void); |
0 | 36 |
void (*set_volume)(byte vol); |
37 |
} HalMusicDriver; |
|
38 |
||
5587
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
39 |
extern HalMusicDriver *_music_driver; |
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
40 |
extern HalSoundDriver *_sound_driver; |
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
41 |
extern HalVideoDriver *_video_driver; |
0 | 42 |
|
43 |
enum DriverType { |
|
44 |
VIDEO_DRIVER = 0, |
|
45 |
SOUND_DRIVER = 1, |
|
46 |
MUSIC_DRIVER = 2, |
|
47 |
}; |
|
48 |
||
5587
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
49 |
#ifdef __cplusplus |
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
50 |
} // extern "C" |
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
51 |
#endif //__cplusplus |
167d9a91ef02
(svn r8038) -Merge: the cpp branch. Effort of KUDr, Celestar, glx, Smoovius, stillunknown and pv2b.
rubidium
parents:
5475
diff
changeset
|
52 |
|
0 | 53 |
#endif /* HAL_H */ |