Search
lxdream.org :: lxdream/src/dreamcast.h :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/dreamcast.h
changeset 144:7f0714e89aaa
prev30:89b30313d757
next167:71c0cc416a64
author nkeynes
date Sat May 20 02:40:51 2006 +0000 (17 years ago)
permissions -rw-r--r--
last change Implement analog joystick (and make sure it defaults to centered)
file annotate diff log raw
1.1 --- a/src/dreamcast.h Sun Dec 25 05:57:00 2005 +0000
1.2 +++ b/src/dreamcast.h Sat May 20 02:40:51 2006 +0000
1.3 @@ -1,5 +1,5 @@
1.4 /**
1.5 - * $Id: dreamcast.h,v 1.8 2005-12-25 05:56:55 nkeynes Exp $
1.6 + * $Id: dreamcast.h,v 1.9 2006-05-15 08:28:48 nkeynes Exp $
1.7 *
1.8 * Public interface for dreamcast.c -
1.9 * Central switchboard for the system. This pulls all the individual modules
1.10 @@ -30,18 +30,39 @@
1.11 #endif
1.12
1.13 #define DEFAULT_TIMESLICE_LENGTH 1000000 /* nanoseconds */
1.14 +#define CONFIG_TYPE_NONE 0
1.15 +#define CONFIG_TYPE_FILE 1
1.16 +#define CONFIG_TYPE_PATH 2
1.17 +#define CONFIG_TYPE_KEY 3
1.18 +
1.19 +#define DEFAULT_CONFIG_FILENAME "dream.conf"
1.20 +
1.21 +typedef struct dreamcast_config_entry {
1.22 + const gchar *key;
1.23 + const int type;
1.24 + const gchar *default_value;
1.25 + gchar *value;
1.26 +} *dreamcast_config_entry_t;
1.27 +
1.28 +typedef struct dreamcast_config_group {
1.29 + const gchar *key;
1.30 + struct dreamcast_config_entry *params;
1.31 +} *dreamcast_config_group_t;
1.32 +
1.33
1.34 void dreamcast_init(void);
1.35 void dreamcast_reset(void);
1.36 void dreamcast_run(void);
1.37 void dreamcast_stop(void);
1.38
1.39 -void dreamcast_load_config( const gchar *filename );
1.40 -void dreamcast_save_config( const gchar *filename );
1.41 +gboolean dreamcast_load_config( const gchar *filename );
1.42 +gboolean dreamcast_save_config( const gchar *filename );
1.43
1.44 int dreamcast_save_state( const gchar *filename );
1.45 int dreamcast_load_state( const gchar *filename );
1.46
1.47 +extern struct dreamcast_config_group dreamcast_config_root[];
1.48 +
1.49 #ifdef __cplusplus
1.50 }
1.51 #endif
.