summaryrefslogtreecommitdiffstatshomepage
path: root/src/emu/gamedrv.h
diff options
context:
space:
mode:
author Miodrag Milanovic <mmicko@gmail.com>2016-03-30 20:38:44 +0200
committer Miodrag Milanovic <mmicko@gmail.com>2016-03-30 20:40:05 +0200
commit9353a1ccb3100a20a58c40f98d10e8a6e38230cc (patch)
tree65337ea475283a5103f3ea8fa50983423e4946b9 /src/emu/gamedrv.h
parentc95d9c0ec3afb1952e51324125b6891be6a81a13 (diff)
Compressed internal layouts [David Haywood]
Diffstat (limited to 'src/emu/gamedrv.h')
-rw-r--r--src/emu/gamedrv.h29
1 files changed, 22 insertions, 7 deletions
diff --git a/src/emu/gamedrv.h b/src/emu/gamedrv.h
index 7fdcaf9e1c4..070c69f6a85 100644
--- a/src/emu/gamedrv.h
+++ b/src/emu/gamedrv.h
@@ -74,7 +74,7 @@ struct game_driver
const rom_entry * rom; // pointer to list of ROMs for the game
const char * compatible_with;
UINT32 flags; // orientation and other flags; see defines below
- const char * default_layout; // default internally defined layout
+ const internal_layout * default_layout; // default internally defined layout
};
@@ -95,7 +95,22 @@ struct game_driver
// standard GAME() macro
#define GAME(YEAR,NAME,PARENT,MACHINE,INPUT,CLASS,INIT,MONITOR,COMPANY,FULLNAME,FLAGS) \
- GAMEL(YEAR,NAME,PARENT,MACHINE,INPUT,CLASS,INIT,MONITOR,COMPANY,FULLNAME,FLAGS,((const char *)0))
+extern const game_driver GAME_NAME(NAME) = \
+{ \
+ __FILE__, \
+ #PARENT, \
+ #NAME, \
+ FULLNAME, \
+ #YEAR, \
+ COMPANY, \
+ MACHINE_CONFIG_NAME(MACHINE), \
+ INPUT_PORTS_NAME(INPUT), \
+ &driver_device::driver_init_wrapper<CLASS, &CLASS::init_##INIT>, \
+ ROM_NAME(NAME), \
+ nullptr, \
+ (MONITOR)|(FLAGS)|MACHINE_TYPE_ARCADE, \
+ nullptr \
+};
// standard macro with additional layout
#define GAMEL(YEAR,NAME,PARENT,MACHINE,INPUT,CLASS,INIT,MONITOR,COMPANY,FULLNAME,FLAGS,LAYOUT) \
@@ -111,9 +126,9 @@ extern const game_driver GAME_NAME(NAME) = \
INPUT_PORTS_NAME(INPUT), \
&driver_device::driver_init_wrapper<CLASS, &CLASS::init_##INIT>, \
ROM_NAME(NAME), \
- NULL, \
+ nullptr, \
(MONITOR)|(FLAGS)|MACHINE_TYPE_ARCADE, \
- &LAYOUT[0] \
+ &LAYOUT \
};
// standard console definition macro
@@ -132,7 +147,7 @@ extern const game_driver GAME_NAME(NAME) = \
ROM_NAME(NAME), \
#COMPAT, \
ROT0|(FLAGS)|MACHINE_TYPE_CONSOLE, \
- NULL \
+ nullptr \
};
// standard computer definition macro
@@ -151,7 +166,7 @@ extern const game_driver GAME_NAME(NAME) = \
ROM_NAME(NAME), \
#COMPAT, \
ROT0|(FLAGS)|MACHINE_TYPE_COMPUTER, \
- NULL \
+ nullptr \
};
// standard system definition macro
@@ -170,7 +185,7 @@ extern const game_driver GAME_NAME(NAME) = \
ROM_NAME(NAME), \
#COMPAT, \
ROT0|(FLAGS)|MACHINE_TYPE_OTHER, \
- NULL \
+ nullptr \
};