Files
@ r5312:ffd375effb01
Branch filter:
Location: cpp/openttd-patchpack/source/hal.h - annotation
r5312:ffd375effb01
1.0 KiB
text/x-c
(svn r7468) -Codechange: [win32] Add some comments to MB/WIDE_TO_WIDE/MB_[BUFFER] macros and
use them some more in win32 code. Also for the clipboard use the convert_from_fs
function instead of calling Win32 API directly. Make the static buffers in OTTD2FS
and FS2OTTD the same size (character-length wise)
use them some more in win32 code. Also for the clipboard use the convert_from_fs
function instead of calling Win32 API directly. Make the static buffers in OTTD2FS
and FS2OTTD the same size (character-length wise)
r2186:5ee653b1b5e1 r2186:5ee653b1b5e1 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r1301:421c809ec9f3 r1093:18f56ef2d029 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r1301:421c809ec9f3 r1093:18f56ef2d029 r0:d63b455452f6 r2228:cc9d133c0351 r0:d63b455452f6 r1829:3dfbdb5a9e01 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r1301:421c809ec9f3 r1093:18f56ef2d029 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r1301:421c809ec9f3 r1093:18f56ef2d029 r0:d63b455452f6 r0:d63b455452f6 r1093:18f56ef2d029 r1093:18f56ef2d029 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r0:d63b455452f6 r4217:96db9b185b25 r0:d63b455452f6 r1093:18f56ef2d029 r0:d63b455452f6 r0:d63b455452f6 | /* $Id$ */
#ifndef HAL_H
#define HAL_H
typedef struct {
const char *(*start)(const char * const *parm);
void (*stop)(void);
} HalCommonDriver;
typedef struct {
const char *(*start)(const char * const *parm);
void (*stop)(void);
void (*make_dirty)(int left, int top, int width, int height);
void (*main_loop)(void);
bool (*change_resolution)(int w, int h);
void (*toggle_fullscreen)(bool fullscreen);
} HalVideoDriver;
typedef struct {
const char *(*start)(const char * const *parm);
void (*stop)(void);
} HalSoundDriver;
typedef struct {
const char *(*start)(const char * const *parm);
void (*stop)(void);
void (*play_song)(const char *filename);
void (*stop_song)(void);
bool (*is_song_playing)(void);
void (*set_volume)(byte vol);
} HalMusicDriver;
VARDEF HalMusicDriver *_music_driver;
VARDEF HalSoundDriver *_sound_driver;
VARDEF HalVideoDriver *_video_driver;
enum DriverType {
VIDEO_DRIVER = 0,
SOUND_DRIVER = 1,
MUSIC_DRIVER = 2,
};
void GameLoop(void);
void CreateConsole(void);
#endif /* HAL_H */
|