From d28cec126a0b96d48d6e2e07744c111131a7b0c3 Mon Sep 17 00:00:00 2001 From: Jasmine Iwanek Date: Sat, 9 Apr 2022 20:09:14 -0400 Subject: [PATCH] src/video --- src/video/vid_ati28800.c | 60 ++++++--- src/video/vid_ati_mach64.c | 55 +++++++-- src/video/vid_cga.c | 85 ++++++++++--- src/video/vid_cl54xx.c | 14 +-- src/video/vid_colorplus.c | 54 ++++++-- src/video/vid_ega.c | 33 +++-- src/video/vid_et4000.c | 30 +++-- src/video/vid_et4000w32.c | 25 +++- src/video/vid_hercules.c | 43 +++++-- src/video/vid_herculesplus.c | 43 +++++-- src/video/vid_ht216.c | 86 +++++++++---- src/video/vid_mda.c | 35 ++++-- src/video/vid_mga.c | 5 +- src/video/vid_nga.c | 98 +++++++++++---- src/video/vid_oak_oti.c | 81 +++++++++--- src/video/vid_ogc.c | 42 +++++-- src/video/vid_paradise.c | 217 +++++++++++++++++---------------- src/video/vid_rtg310x.c | 34 ++++-- src/video/vid_s3.c | 145 ++++++++++++++++------ src/video/vid_s3_virge.c | 140 ++++++++++++++++----- src/video/vid_sigma.c | 114 +++++++++++++---- src/video/vid_table.c | 44 +++---- src/video/vid_tgui9440.c | 4 +- src/video/vid_tvga.c | 30 +++-- src/video/vid_voodoo.c | 24 ++-- src/video/vid_voodoo_banshee.c | 211 +++++++++++++++----------------- 26 files changed, 1209 insertions(+), 543 deletions(-) diff --git a/src/video/vid_ati28800.c b/src/video/vid_ati28800.c index a305c80c0..87abb7da8 100644 --- a/src/video/vid_ati28800.c +++ b/src/video/vid_ati28800.c @@ -708,29 +708,61 @@ ati28800_force_redraw(void *priv) // clang-format off static const device_config_t ati28800_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 512, "", { 0 }, - { - { "256 kB", 256 }, - { "512 kB", 512 }, - { "1 MB", 1024 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 512, + .selection = { + { + .description = "256 kB", + .value = 256 + }, + { + .description = "512 kB", + .value = 512 + }, + { + .description = "1 MB", + .value = 1024 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; #if defined(DEV_BRANCH) && defined(USE_XL24) static const device_config_t ati28800_wonderxl_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 512, "", { 0 }, - { - { "256 kB", 256 }, - { "512 kB", 512 }, - { "1 MB", 1024 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 512, + .selection = { + { + .description = "256 kB", + .value = 256 + }, + { + .description = "512 kB", + .value = 512 + }, + { + .description = "1 MB", + .value = 1024 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; #endif // clang-format on diff --git a/src/video/vid_ati_mach64.c b/src/video/vid_ati_mach64.c index db111fa37..3cfc22db3 100644 --- a/src/video/vid_ati_mach64.c +++ b/src/video/vid_ati_mach64.c @@ -3684,27 +3684,56 @@ void mach64_force_redraw(void *p) // clang-format off static const device_config_t mach64gx_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 4, "", { 0 }, - { - { "1 MB", 1 }, - { "2 MB", 2 }, - { "4 MB", 4 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 4, + .selection = { + { + .description = "1 MB", + .value = 1 + }, + { + .description = "2 MB", + .value = 2 + }, + { + .description = "4 MB", + .value = 4 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; static const device_config_t mach64vt2_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 4, "", { 0 }, - { - { "2 MB", 2 }, - { "4 MB", 4 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 4, + .selection = { + { + .description = "2 MB", + .value = 2 + }, + { + .description = "4 MB", + .value = 4 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; // clang-format on diff --git a/src/video/vid_cga.c b/src/video/vid_cga.c index 3a0eacc96..9369f1451 100644 --- a/src/video/vid_cga.c +++ b/src/video/vid_cga.c @@ -578,37 +578,82 @@ cga_speed_changed(void *p) // clang-format off const device_config_t cga_config[] = { { - "display_type", "Display type", CONFIG_SELECTION, "", CGA_RGB, "", { 0 }, - { - { "RGB", CGA_RGB }, - { "Composite", CGA_COMPOSITE }, - { "" } + .name = "display_type", + .description = "Display type", + .type = CONFIG_SELECTION, + .default_int = CGA_RGB, + .selection = { + { + .description = "RGB", + .value = CGA_RGB + }, + { + .description = "Composite", + .value = CGA_COMPOSITE + }, + { + .description = "" + } } }, { - "composite_type", "Composite type", CONFIG_SELECTION, "", COMPOSITE_OLD, "", { 0 }, - { - { "Old", COMPOSITE_OLD }, - { "New", COMPOSITE_NEW }, - { "" } + .name = "composite_type", + .description = "Composite type", + .type = CONFIG_SELECTION, + .default_int = COMPOSITE_OLD, + .selection = { + { + .description = "Old", + .value = COMPOSITE_OLD + }, + { + .description = "New", + .value = COMPOSITE_NEW + }, + { + .description = "" + } } }, { - "rgb_type", "RGB type", CONFIG_SELECTION, "", 0, "", { 0 }, - { - { "Color", 0 }, - { "Green Monochrome", 1 }, - { "Amber Monochrome", 2 }, - { "Gray Monochrome", 3 }, - { "Color (no brown)", 4 }, - { "" } + .name = "rgb_type", + .description = "RGB type", + .type = CONFIG_SELECTION, + .default_int = 0, + .selection = { + { + .description = "Color", + .value = 0 + }, + { + .description = "Green Monochrome", + .value = 1 + }, + { + .description = "Amber Monochrome", + .value = 2 + }, + { + .description = "Gray Monochrome", + .value = 3 + }, + { + .description = "Color (no brown)", + .value = 4 + }, + { + .description = "" + } } }, { - "snow_enabled", "Snow emulation", CONFIG_BINARY, "", 1 + .name = "snow_enabled", + .description = "Snow emulation", + .type = CONFIG_BINARY, + .default_int = 1 }, { - "", "", -1 + .type = CONFIG_END } }; // clang-format on diff --git a/src/video/vid_cl54xx.c b/src/video/vid_cl54xx.c index a39b9aea4..6663080b8 100644 --- a/src/video/vid_cl54xx.c +++ b/src/video/vid_cl54xx.c @@ -4304,7 +4304,7 @@ static const device_config_t gd542x_config[] = { .default_int = 512 }, { - .type = -1 + .type = CONFIG_END } }; @@ -4333,7 +4333,7 @@ static const device_config_t gd5426_config[] = { .default_int = 2048 }, { - .type = -1 + .type = CONFIG_END } }; @@ -4362,7 +4362,7 @@ static const device_config_t gd5428_onboard_config[] = { .default_int = 2048 }, { - .type = -1 + .type = CONFIG_END } }; @@ -4387,7 +4387,7 @@ static const device_config_t gd5429_config[] = { .default_int = 2 }, { - .type = -1 + .type = CONFIG_END } }; @@ -4412,7 +4412,7 @@ static const device_config_t gd5440_onboard_config[] = { .default_int = 2 }, { - .type = -1 + .type = CONFIG_END } }; @@ -4441,7 +4441,7 @@ static const device_config_t gd5434_config[] = { .default_int = 4 }, { - .type = -1 + .type = CONFIG_END } }; @@ -4470,7 +4470,7 @@ static const device_config_t gd5434_onboard_config[] = { .default_int = 4 }, { - .type = -1 + .type = CONFIG_END } }; diff --git a/src/video/vid_colorplus.c b/src/video/vid_colorplus.c index bd68c43b9..2dc2d2308 100644 --- a/src/video/vid_colorplus.c +++ b/src/video/vid_colorplus.c @@ -427,27 +427,55 @@ void colorplus_speed_changed(void *p) cga_recalctimings(&colorplus->cga); } - static const device_config_t colorplus_config[] = { // clang-format off { - "display_type", "Display type", CONFIG_SELECTION, "", CGA_RGB, "", { 0 }, - { - { "RGB", CGA_RGB }, - { "Composite", CGA_COMPOSITE }, - { "" } + .name = "display_type", + .description = "Display type", + .type = CONFIG_SELECTION, + .default_int = CGA_RGB, + .selection = { + { + .description = "RGB", + .value = CGA_RGB + }, + { + .description = "Composite", + .value = CGA_COMPOSITE + }, + { + .description = "" + } } }, { - "composite_type", "Composite type", CONFIG_SELECTION, "", COMPOSITE_OLD, "", { 0 }, - { - { "Old", COMPOSITE_OLD }, - { "New", COMPOSITE_NEW }, - { "" } + .name = "composite_type", + .description = "Composite type", + .type = CONFIG_SELECTION, + .default_int = COMPOSITE_OLD, + .selection = { + { + .description = "Old", + .value = COMPOSITE_OLD + }, + { + .description = "New", + .value = COMPOSITE_NEW + }, + { + .description = "" + } } }, - { "snow_enabled", "Snow emulation", CONFIG_BINARY, "", 1 }, - { "", "", -1 } + { + .name = "snow_enabled", + .description = "Snow emulation", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_ega.c b/src/video/vid_ega.c index 41a34ef09..e76c68afa 100644 --- a/src/video/vid_ega.c +++ b/src/video/vid_ega.c @@ -1179,13 +1179,30 @@ ega_speed_changed(void *p) static const device_config_t ega_config[] = { // clang-format off { - "memory", "Memory size", CONFIG_SELECTION, "", 256, "", { 0 }, - { - { "32 kB", 32 }, - { "64 kB", 64 }, - { "128 kB", 128 }, - { "256 kB", 256 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 256, + .selection = { + { + .description = "32 kB", + .value = 32 + }, + { + .description = "64 kB", + .value = 64 + }, + { + .description = "128 kB", + .value = 128 + }, + { + .description = "256 kB", + .value = 256 + }, + { + .description = "" + } } }, { @@ -1228,7 +1245,7 @@ static const device_config_t ega_config[] = { .default_int = 9 }, { - .type = -1 + .type = CONFIG_END } // clang-format on }; diff --git a/src/video/vid_et4000.c b/src/video/vid_et4000.c index 119c0b0ed..c18a422a3 100644 --- a/src/video/vid_et4000.c +++ b/src/video/vid_et4000.c @@ -807,15 +807,31 @@ et4000_kasan_available(void) static const device_config_t et4000_config[] = { // clang-format off { - "memory", "Memory size", CONFIG_SELECTION, "", 1024, "", { 0 }, - { - { "256 KB", 256 }, - { "512 KB", 512 }, - { "1 MB", 1024 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 1024, + .selection = { + { + .description = "256 KB", + .value = 256 + }, + { + .description = "512 KB", + .value = 512 + }, + { + .description = "1 MB", + .value = 1024 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_et4000w32.c b/src/video/vid_et4000w32.c index e318e2099..a69736d40 100644 --- a/src/video/vid_et4000w32.c +++ b/src/video/vid_et4000w32.c @@ -2193,14 +2193,27 @@ et4000w32p_force_redraw(void *p) static const device_config_t et4000w32p_config[] = { // clang-format off { - "memory", "Memory size", CONFIG_SELECTION, "", 2, "", { 0 }, - { - { "1 MB", 1 }, - { "2 MB", 2 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 2, + .selection = { + { + .description = "1 MB", + .value = 1 + }, + { + .description = "2 MB", + .value = 2 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_hercules.c b/src/video/vid_hercules.c index bc69a785a..d310fa419 100644 --- a/src/video/vid_hercules.c +++ b/src/video/vid_hercules.c @@ -608,21 +608,44 @@ speed_changed(void *priv) recalc_timings(dev); } - static const device_config_t hercules_config[] = { // clang-format off { - "rgb_type", "Display type", CONFIG_SELECTION, "", 0, "", { 0 }, - { - { "Default", 0 }, - { "Green", 1 }, - { "Amber", 2 }, - { "Gray", 3 }, - { "" } + .name = "rgb_type", + .description = "Display type", + .type = CONFIG_SELECTION, + .default_int = 0, + .selection = { + { + .description = "Default", + .value = 0 + }, + { + .description = "Green", + .value = 1 + }, + { + .description = "Amber", + .value = 2 + }, + { + .description = "Gray", + .value = 3 + }, + { + .description = "" + } } }, - { "blend", "Blend", CONFIG_BINARY, "", 1 }, - { "", "", -1 } + { + .name = "blend", + .description = "Blend", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_herculesplus.c b/src/video/vid_herculesplus.c index ad30a6393..4233bec7b 100644 --- a/src/video/vid_herculesplus.c +++ b/src/video/vid_herculesplus.c @@ -693,21 +693,44 @@ speed_changed(void *priv) recalc_timings(dev); } - static const device_config_t herculesplus_config[] = { // clang-format off { - "rgb_type", "Display type", CONFIG_SELECTION, "", 0, "", { 0 }, - { - { "Default", 0 }, - { "Green", 1 }, - { "Amber", 2 }, - { "Gray", 3 }, - { "" } + .name = "rgb_type", + .description = "Display type", + .type = CONFIG_SELECTION, + .default_int = 0, + .selection = { + { + .description = "Default", + .value = 0 + }, + { + .description = "Green", + .value = 1 + }, + { + .description = "Amber", + .value = 2 + }, + { + .description = "Gray", + .value = 3 + }, + { + .description = "" + } } }, - { "blend", "Blend", CONFIG_BINARY, "", 1 }, - { "", "", -1 } + { + .name = "blend", + .description = "Blend", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_ht216.c b/src/video/vid_ht216.c index a95899d97..a9b54c1f0 100644 --- a/src/video/vid_ht216.c +++ b/src/video/vid_ht216.c @@ -1621,44 +1621,88 @@ ht216_force_redraw(void *p) ht216->svga.fullchange = changeframecount; } - static const device_config_t v7_vga_1024i_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 512, "", { 0 }, - { - { "256 kB", 256 }, - { "512 kB", 512 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 512, + .selection = { + { + .description = "256 kB", + .value = 256 + }, + { + .description = "512 kB", + .value = 512 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; // clang-format off static const device_config_t ht216_32_standalone_config[] = { { - "monitor_type", "Monitor type", CONFIG_SELECTION, "", 0x18, "", { 0 }, - { - { "Mono Interlaced", 0x00 }, - { "Mono Non-Interlaced", 0x08 }, - { "Color Interlaced", 0x10 }, - { "Color Non-Interlaced", 0x18 }, - { "" } + .name = "monitor_type", + .description = "Monitor type", + .type = CONFIG_SELECTION, + .default_int = 0x18, + .selection = { + { + .description = "Mono Interlaced", + .value = 0x00 + }, + { + .description = "Mono Non-Interlaced", + .value = 0x08 + }, + { + .description = "Color Interlaced", + .value = 0x10 + }, + { + .description = "Color Non-Interlaced", + .value = 0x18 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; static const device_config_t radius_svga_multiview_config[] = { { - "extensions", "Extensions", CONFIG_SELECTION, "", 0x00, "", { 0 }, - { - { "Extensions Enabled", 0x00 }, - { "Extensions Disabled", 0x02 }, - { "" } + .name = "extensions", + .description = "Extensions", + .type = CONFIG_SELECTION, + .default_int = 0x00, + .selection = { + { + .description = "Extensions Enabled", + .value = 0x00 + }, + { + .description = "Extensions Disabled", + .value = 0x02 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; // clang-format on diff --git a/src/video/vid_mda.c b/src/video/vid_mda.c index 83987ef83..abd6c7c88 100644 --- a/src/video/vid_mda.c +++ b/src/video/vid_mda.c @@ -330,16 +330,35 @@ void mda_speed_changed(void *p) static const device_config_t mda_config[] = { // clang-format off { - "rgb_type", "Display type", CONFIG_SELECTION, "", 0, "", { 0 }, - { - { "Default", 0 }, - { "Green", 1 }, - { "Amber", 2 }, - { "Gray", 3 }, - { "" } + .name = "rgb_type", + .description = "Display type", + .type = CONFIG_SELECTION, + .default_int = 0, + .selection = { + { + .description = "Default", + .value = 0 + }, + { + .description = "Green", + .value = 1 + }, + { + .description = "Amber", + .value = 2 + }, + { + .description = "Gray", + .value = 3 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_mga.c b/src/video/vid_mga.c index ea365e2ba..bfb83d9c2 100644 --- a/src/video/vid_mga.c +++ b/src/video/vid_mga.c @@ -5336,7 +5336,6 @@ mystique_force_redraw(void *p) mystique->svga.fullchange = changeframecount; } - static const device_config_t mystique_config[] = { // clang-format off { @@ -5363,7 +5362,9 @@ static const device_config_t mystique_config[] = { }, .default_int = 8 }, - { .type = -1 } + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_nga.c b/src/video/vid_nga.c index 4d500b178..befe01671 100644 --- a/src/video/vid_nga.c +++ b/src/video/vid_nga.c @@ -598,42 +598,94 @@ nga_init(const device_t *info) return nga; } - const device_config_t nga_config[] = { // clang-format off { - "rgb_type", "RGB type", CONFIG_SELECTION, "", 0, "", { 0 }, - { - { "Color", 0 }, - { "Green Monochrome", 1 }, - { "Amber Monochrome", 2 }, - { "Gray Monochrome", 3 }, - { "Color (no brown)", 4 }, - { "" } + .name = "rgb_type", + .description = "RGB type", + .type = CONFIG_SELECTION, + .default_int = 0, + .selection = { + { + .description = "Color", + .value = 0 + }, + { + .description = "Green Monochrome", + .value = 1 + }, + { + .description = "Amber Monochrome", + .value = 2 + }, + { + .description = "Gray Monochrome", + .value = 3 + }, + { + .description = "Color (no brown)", + .value = 4 + }, + { + .description = "" + } } }, { - "snow_enabled", "Snow emulation", CONFIG_BINARY, "", 1 + .name = "snow_enabled", + .description = "Snow emulation", + .type = CONFIG_BINARY, + .default_int = 1 }, { - "memory", "Memory size", CONFIG_SELECTION, "", 64, "", { 0 }, - { - { "32 KB", 32 }, - { "64 KB", 64 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 64, + .selection = { + { + .description = "32 KB", + .value = 32 + }, + { + .description = "64 KB", + .value = 64 + }, + { + .description = "" + } } }, { - "charset", "Character set", CONFIG_SELECTION, "", 0, "", { 0 }, - { - { "U.S. English", 0 }, - { "Scandinavian", 1 }, - { "Other languages", 2 }, - { "E.F. Hutton", 3 }, - { "" } + .name = "charset", + .description = "Character set", + .type = CONFIG_SELECTION, + .default_int = 0, + .selection = { + { + .description = "U.S. English", + .value = 0 + }, + { + .description = "Scandinavian", + .value = 1 + }, + { + .description = "Other languages", + .value = 2 + }, + { + .description = "E.F. Hutton", + .value = 3 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_oak_oti.c b/src/video/vid_oak_oti.c index fb1945aa7..210afc2b2 100644 --- a/src/video/vid_oak_oti.c +++ b/src/video/vid_oak_oti.c @@ -500,43 +500,84 @@ oti067_m300_available(void) return(rom_present(BIOS_067_M300_08_PATH)); } - // clang-format off static const device_config_t oti067_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 512, "", { 0 }, - { - { "256 kB", 256 }, - { "512 kB", 512 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 512, + .selection = { + { + .description = "256 kB", + .value = 256 + }, + { + .description = "512 kB", + .value = 512 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; static const device_config_t oti067_ama932j_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 256, "", { 0 }, - { - { "256 kB", 256 }, - { "512 kB", 512 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 256, + .selection = { + { + .description = "256 kB", + .value = 256 + }, + { + .description = "512 kB", + .value = 512 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; static const device_config_t oti077_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 1024, "", { 0 }, - { - { "256 kB", 256 }, - { "512 kB", 512 }, - { "1 MB", 1024 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 1024, + .selection = { + { + .description = "256 kB", + .value = 256 + }, + { + .description = "512 kB", + .value = 512 + }, + { + .description = "1 MB", + .value = 1024 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; // clang-format on diff --git a/src/video/vid_ogc.c b/src/video/vid_ogc.c index 9e751948f..0487d691d 100644 --- a/src/video/vid_ogc.c +++ b/src/video/vid_ogc.c @@ -639,17 +639,41 @@ const device_config_t ogc_m24_config[] = { // clang-format off { /* Olivetti / ATT compatible displays */ - "rgb_type", "RGB type", CONFIG_SELECTION, "", CGA_RGB, "", { 0 }, - { - { "Color", 0 }, - { "Green Monochrome", 1 }, - { "Amber Monochrome", 2 }, - { "Gray Monochrome", 3 }, - { "" } + .name = "rgb_type", + .description = "RGB type", + .type = CONFIG_SELECTION, + .default_int = CGA_RGB, + .selection = { + { + .description = "Color", + .value = 0 + }, + { + .description = "Green Monochrome", + .value = 1 + }, + { + .description = "Amber Monochrome", + .value = 2 + }, + { + .description = "Gray Monochrome", + .value = 3 + }, + { + .description = "" + } } }, - { "snow_enabled", "Snow emulation", CONFIG_BINARY, "", 1, }, - { "", "", -1 } + { + .name = "snow_enabled", + .description = "Snow emulation", + .type = CONFIG_BINARY, + .default_int = 1, + }, + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_paradise.c b/src/video/vid_paradise.c index c64afb7d5..59b9f2247 100644 --- a/src/video/vid_paradise.c +++ b/src/video/vid_paradise.c @@ -717,126 +717,139 @@ void paradise_force_redraw(void *p) paradise->svga.fullchange = changeframecount; } -const device_t paradise_pvga1a_pc2086_device = -{ - "Paradise PVGA1A (Amstrad PC2086)", - "pvga1a_pc2086", - 0, - PVGA1A, - paradise_pvga1a_pc2086_init, - paradise_close, - NULL, - { NULL }, - paradise_speed_changed, - paradise_force_redraw, - NULL +const device_t paradise_pvga1a_pc2086_device = { + .name = "Paradise PVGA1A (Amstrad PC2086)", + .internal_name = "pvga1a_pc2086", + .flags = 0, + .local = PVGA1A, + .init = paradise_pvga1a_pc2086_init, + .close = paradise_close, + .reset = NULL, + { .available = NULL }, + .speed_changed = paradise_speed_changed, + .force_redraw = paradise_force_redraw, + .config = NULL }; -const device_t paradise_pvga1a_pc3086_device = -{ - "Paradise PVGA1A (Amstrad PC3086)", - "pvga1a_pc3086", - 0, - PVGA1A, - paradise_pvga1a_pc3086_init, - paradise_close, - NULL, - { NULL }, - paradise_speed_changed, - paradise_force_redraw, - NULL +const device_t paradise_pvga1a_pc3086_device = { + .name = "Paradise PVGA1A (Amstrad PC3086)", + .internal_name = "pvga1a_pc3086", + .flags = 0, + .local = PVGA1A, + .init = paradise_pvga1a_pc3086_init, + .close = paradise_close, + .reset = NULL, + { .available = NULL }, + .speed_changed = paradise_speed_changed, + .force_redraw = paradise_force_redraw, + .config = NULL }; -static const device_config_t paradise_pvga1a_config[] = -{ - { - "memory", "Memory size", CONFIG_SELECTION, "", 512, "", { 0 }, - { - { - "256 kB", 256 - }, - { - "512 kB", 512 - }, - { - "" - } - } - }, - { - "", "", -1 +static const device_config_t paradise_pvga1a_config[] = { + { + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 512, + .selection = { + { + .description = "256 kB", + .value = 256 + }, + { + .description = "512 kB", + .value = 512 + }, + { + .description = "" + } } + }, + { + .type = CONFIG_END + } }; -const device_t paradise_pvga1a_ncr3302_device = -{ - "Paradise PVGA1A (NCR 3302)", - "pvga1a_ncr3302", - 0, - PVGA1A, - paradise_pvga1a_ncr3302_init, - paradise_close, - NULL, - { NULL }, - paradise_speed_changed, - paradise_force_redraw, - paradise_pvga1a_config +const device_t paradise_pvga1a_ncr3302_device = { + .name = "Paradise PVGA1A (NCR 3302)", + .internal_name = "pvga1a_ncr3302", + .flags = 0, + .local = PVGA1A, + .init = paradise_pvga1a_ncr3302_init, + .close = paradise_close, + .reset = NULL, + { .available = NULL }, + .speed_changed = paradise_speed_changed, + .force_redraw = paradise_force_redraw, + .config = paradise_pvga1a_config }; -const device_t paradise_pvga1a_device = -{ - "Paradise PVGA1A", - "pvga1a", - DEVICE_ISA, - PVGA1A, - paradise_pvga1a_standalone_init, - paradise_close, - NULL, - { paradise_pvga1a_standalone_available }, - paradise_speed_changed, - paradise_force_redraw, - paradise_pvga1a_config +const device_t paradise_pvga1a_device = { + .name = "Paradise PVGA1A", + .internal_name = "pvga1a", + .flags = DEVICE_ISA, + .local = PVGA1A, + .init = paradise_pvga1a_standalone_init, + .close = paradise_close, + .reset = NULL, + { .available = paradise_pvga1a_standalone_available }, + .speed_changed = paradise_speed_changed, + .force_redraw = paradise_force_redraw, + .config = paradise_pvga1a_config }; -const device_t paradise_wd90c11_megapc_device = -{ - "Paradise WD90C11 (Amstrad MegaPC)", - "wd90c11_megapc", - 0, - WD90C11, - paradise_wd90c11_megapc_init, - paradise_close, - NULL, - { NULL }, - paradise_speed_changed, - paradise_force_redraw, - NULL + +const device_t paradise_wd90c11_megapc_device = { + .name = "Paradise WD90C11 (Amstrad MegaPC)", + .internal_name = "wd90c11_megapc", + .flags = 0, + .local = WD90C11, + .init = paradise_wd90c11_megapc_init, + .close = paradise_close, + .reset = NULL, + { .available = NULL }, + .speed_changed = paradise_speed_changed, + .force_redraw = paradise_force_redraw, + .config = NULL }; -const device_t paradise_wd90c11_device = -{ - "Paradise WD90C11-LR", - "wd90c11", - DEVICE_ISA, - WD90C11, - paradise_wd90c11_standalone_init, - paradise_close, - NULL, - { paradise_wd90c11_standalone_available }, - paradise_speed_changed, - paradise_force_redraw, - NULL + +const device_t paradise_wd90c11_device = { + .name = "Paradise WD90C11-LR", + .internal_name = "wd90c11", + .flags = DEVICE_ISA, + .local = WD90C11, + .init = paradise_wd90c11_standalone_init, + .close = paradise_close, + .reset = NULL, + { .available = paradise_wd90c11_standalone_available }, + .speed_changed = paradise_speed_changed, + .force_redraw = paradise_force_redraw, + .config = NULL }; static const device_config_t paradise_wd90c30_config[] = { // clang-format off { - "memory", "Memory size", CONFIG_SELECTION, "", 1024, "", { 0 }, - { - { "512 kB", 512 }, - { "1 MB", 1024 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 1024, + .selection = { + { + .description = "512 kB", + .value = 512 + }, + { + .description = "1 MB", + .value = 1024 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_rtg310x.c b/src/video/vid_rtg310x.c index 7c046782a..2eb82626b 100644 --- a/src/video/vid_rtg310x.c +++ b/src/video/vid_rtg310x.c @@ -361,15 +361,31 @@ rtg_available(void) static const device_config_t rtg_config[] = { // clang-format off { - "memory", "Memory size", CONFIG_SELECTION, "", 1024, "", { 0 }, - { - { "256 KB", 256 }, - { "512 KB", 512 }, - { "1 MB", 1024 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 1024, + .selection = { + { + .description = "256 KB", + .value = 256 + }, + { + .description = "512 KB", + .value = 512 + }, + { + .description = "1 MB", + .value = 1024 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } // clang-format on }; @@ -379,8 +395,8 @@ const device_t realtek_rtg3106_device = { .flags = DEVICE_ISA | DEVICE_AT, .local = 2, .init = rtg_init, - .close = rtg_close, - .reset = NULL, + .close = rtg_close, + .reset = NULL, { .available = rtg_available }, .speed_changed = rtg_speed_changed, .force_redraw = rtg_force_redraw, diff --git a/src/video/vid_s3.c b/src/video/vid_s3.c index c9fd1f41a..23184560d 100644 --- a/src/video/vid_s3.c +++ b/src/video/vid_s3.c @@ -7611,67 +7611,144 @@ static void s3_force_redraw(void *p) static const device_config_t s3_orchid_86c911_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 1, "", { 0 }, - { - { "512 KB", 0 }, - { "1 MB", 1 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 1, + .selection = { + { + .description = "512 KB", + .value = 0 + }, + { + .description = "1 MB", + .value = 1 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; static const device_config_t s3_9fx_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 2, "", { 0 }, - { - { "1 MB", 1 }, - { "2 MB", 2 }, + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 2, + .selection = { + { + .description = "1 MB", + .value = 1 + }, + { + .description = "2 MB", + .value = 2 + }, /*Trio64 also supports 4 MB, however the Number Nine BIOS does not*/ - { "" } + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; static const device_config_t s3_phoenix_trio32_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 2, "", { 0 }, - { - { "512 KB", 0 }, - { "1 MB", 1 }, - { "2 MB", 2 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 2, + .selection = { + { + .description = "512 KB", + .value = 0 + }, + { + .description = "1 MB", + .value = 1 + }, + { + .description = "2 MB", + .value = 2 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; static const device_config_t s3_standard_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 4, "", { 0 }, - { - { "1 MB", 1 }, - { "2 MB", 2 }, - { "4 MB", 4 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 4, + .selection = { + { + .description = "1 MB", + .value = 1 + }, + { + .description = "2 MB", + .value = 2 + }, + { + .description = "4 MB", + .value = 4 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; static const device_config_t s3_968_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 4, "", { 0 }, - { - { "1 MB", 1 }, - { "2 MB", 2 }, - { "4 MB", 4 }, - { "8 MB", 8 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 4, + .selection = { + { + .description = "1 MB", + .value = 1 + }, + { + .description = "2 MB", + .value = 2 + }, + { + .description = "4 MB", + .value = 4 + }, + { + .description = "8 MB", + .value = 8 + }, + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } }; const device_t s3_orchid_86c911_isa_device = { diff --git a/src/video/vid_s3_virge.c b/src/video/vid_s3_virge.c index eec18bf32..0e9f5d66c 100644 --- a/src/video/vid_s3_virge.c +++ b/src/video/vid_s3_virge.c @@ -4219,51 +4219,135 @@ static void s3_virge_force_redraw(void *p) static const device_config_t s3_virge_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 4, "", { 0 }, - { - { "2 MB", 2 }, - { "4 MB", 4 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 4, + .selection = { + { + .description = "2 MB", + .value = 2 + }, + { + .description = "4 MB", + .value = 4 + }, + { + .description = "" + } } }, - { "bilinear", "Bilinear filtering", CONFIG_BINARY, "", 1 }, - { "dithering", "Dithering", CONFIG_BINARY, "", 1 }, - { "", "", -1 } + { + .name = "bilinear", + .description = "Bilinear filtering", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .name = "dithering", + .description = "Dithering", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .type = CONFIG_END + } }; static const device_config_t s3_virge_stb_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 4, "", { 0 }, - { - { "2 MB", 2 }, - { "4 MB", 4 }, - { "8 MB", 8 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 4, + .selection = { + { + .description = "2 MB", + .value = 2 + }, + { + .description = "4 MB", + .value = 4 + }, + { + .description = "8 MB", + .value = 8 + }, + { + .description = "" + } } }, - { "bilinear", "Bilinear filtering", CONFIG_BINARY, "", 1 }, - { "dithering", "Dithering", CONFIG_BINARY, "", 1 }, - { "", "", -1 } + { + .name = "bilinear", + .description = "Bilinear filtering", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .name = "dithering", + .description = "Dithering", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .type = CONFIG_END + } }; static const device_config_t s3_virge_357_config[] = { - { "bilinear", "Bilinear filtering", CONFIG_BINARY, "", 1 }, - { "dithering", "Dithering", CONFIG_BINARY, "", 1 }, - { "", "", -1 } + { + .name = "bilinear", + .description = "Bilinear filtering", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .name = "dithering", + .description = "Dithering", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .type = CONFIG_END + } }; static const device_config_t s3_trio3d2x_config[] = { { - "memory", "Memory size", CONFIG_SELECTION, "", 4, "", { 0 }, - { - { "4 MB", 4 }, - { "8 MB", 8 }, - { "" } + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 4, + .selection = { + { + .description = "4 MB", + .value = 4 + }, + { + .description = "8 MB", + .value = 8 + }, + { + .description = "" + } } }, - { "bilinear", "Bilinear filtering", CONFIG_BINARY, "", 1 }, - { "dithering", "Dithering", CONFIG_BINARY, "", 1 }, - { "", "", -1 } + { + .name = "bilinear", + .description = "Bilinear filtering", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .name = "dithering", + .description = "Dithering", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .type = CONFIG_END + } }; const device_t s3_virge_325_pci_device = { diff --git a/src/video/vid_sigma.c b/src/video/vid_sigma.c index bddce455c..a6372ad00 100644 --- a/src/video/vid_sigma.c +++ b/src/video/vid_sigma.c @@ -880,39 +880,103 @@ sigma_speed_changed(void *p) sigma_recalctimings(sigma); } - device_config_t sigma_config[] = { // clang-format off { - "rgb_type", "RGB type", CONFIG_SELECTION, "", 0, "", { 0 }, - { - { "Color", 0 }, - { "Green Monochrome", 1 }, - { "Amber Monochrome", 2 }, - { "Gray Monochrome", 3 }, - { "Color (no brown)", 4 }, - { "" } + .name = "rgb_type", + .description = "RGB type", + .type = CONFIG_SELECTION, + .default_int = 0, + .selection = { + { + .description = "Color", + .value = 0 + }, + { + .description = "Green Monochrome", + .value = 1 + }, + { + .description = "Amber Monochrome", + .value = 2 + }, + { + .description = "Gray Monochrome", + .value = 3 + }, + { + .description = "Color (no brown)", + .value = 4 + }, + { + .description = "" + } } }, - { "enable_nmi", "Enable NMI for CGA emulation", CONFIG_BINARY, "", 1 }, { - "bios_addr", "BIOS Address", CONFIG_HEX20, "", 0xc0000, "", { 0 }, - { - { "C000H", 0xc0000 }, - { "C800H", 0xc8000 }, - { "CC00H", 0xcc000 }, - { "D000H", 0xd0000 }, - { "D400H", 0xd4000 }, - { "D800H", 0xd8000 }, - { "DC00H", 0xdc000 }, - { "E000H", 0xe0000 }, - { "E400H", 0xe4000 }, - { "E800H", 0xe8000 }, - { "EC00H", 0xec000 }, - { "" } + .name = "enable_nmi", + .description = "Enable NMI for CGA emulation", + .type = CONFIG_BINARY, + .default_int = 1 + }, + { + .name = "bios_addr", + .description = "BIOS Address", + .type = CONFIG_HEX20, + .default_int = 0xc0000, + .selection = { + { + .description = "C000H", + .value = 0xc0000 + }, + { + .description = "C800H", + .value = 0xc8000 + }, + { + .description = "CC00H", + .value = 0xcc000 + }, + { + .description = "D000H", + .value = 0xd0000 + }, + { + .description = "D400H", + .value = 0xd4000 + }, + { + .description = "D800H", + .value = 0xd8000 + }, + { + .description = "DC00H", + .value = 0xdc000 + }, + { + .description = "E000H", + .value = 0xe0000 + }, + { + .description = "E400H", + .value = 0xe4000 + }, + { + .description = "E800H", + .value = 0xe8000 + }, + { + .description = "EC00H", + .value = 0xec000 + }, + { + .description = "" + } }, }, - { "", "", -1 } + { + .type = CONFIG_END + } // clang-format on }; diff --git a/src/video/vid_table.c b/src/video/vid_table.c index ccd9c4071..a4374796d 100644 --- a/src/video/vid_table.c +++ b/src/video/vid_table.c @@ -47,31 +47,31 @@ static video_timings_t timing_default = {VIDEO_ISA, 8, 16, 32, 8, 16, 32}; static int was_reset = 0; - static const device_t vid_none_device = { - "None", - "none", - 0, - 0, - NULL, - NULL, - NULL, - { NULL }, - NULL, - NULL, - NULL + .name = "None", + .internal_name = "none", + .flags = 0, + .local = 0, + .init = NULL, + .close = NULL, + .reset = NULL, + { .available = NULL }, + .speed_changed = NULL, + .force_redraw = NULL, + .config = NULL }; static const device_t vid_internal_device = { - "Internal", - "internal", - 0, - 0, - NULL, - NULL, NULL, - { NULL }, - NULL, - NULL, - NULL + .name = "Internal", + .internal_name = "internal", + .flags = 0, + .local = 0, + .init = NULL, + .close = NULL, + .reset = NULL, + { .available = NULL }, + .speed_changed = NULL, + .force_redraw = NULL, + .config = NULL }; static const VIDEO_CARD diff --git a/src/video/vid_tgui9440.c b/src/video/vid_tgui9440.c index c6eb5ff8c..9cf7e1ff7 100644 --- a/src/video/vid_tgui9440.c +++ b/src/video/vid_tgui9440.c @@ -3193,7 +3193,7 @@ static const device_config_t tgui9440_config[] = { .default_int = 2 }, { - .type = -1 + .type = CONFIG_END } }; @@ -3222,7 +3222,7 @@ static const device_config_t tgui96xx_config[] = { .default_int = 4 }, { - .type = -1 + .type = CONFIG_END } }; // clang-format on diff --git a/src/video/vid_tvga.c b/src/video/vid_tvga.c index 6842ea362..8d488552e 100644 --- a/src/video/vid_tvga.c +++ b/src/video/vid_tvga.c @@ -446,16 +446,32 @@ void tvga_force_redraw(void *p) static const device_config_t tvga_config[] = { // clang-format off { - "memory", "Memory size", CONFIG_SELECTION, "", 1024, "", { 0 }, - { - { "256 kB", 256 }, - { "512 kB", 512 }, - { "1 MB", 1024 }, + .name = "memory", + .description = "Memory size", + .type = CONFIG_SELECTION, + .default_int = 1024, + .selection = { + { + .description = "256 kB", + .value = 256 + }, + { + .description = "512 kB", + .value = 512 + }, + { + .description = "1 MB", + .value = 1024 + }, /*Chip supports 2mb, but drivers are buggy*/ - { "" } + { + .description = "" + } } }, - { "", "", -1 } + { + .type = CONFIG_END + } // clang-format off }; diff --git a/src/video/vid_voodoo.c b/src/video/vid_voodoo.c index 76e6c4009..7631dcf8f 100644 --- a/src/video/vid_voodoo.c +++ b/src/video/vid_voodoo.c @@ -1418,22 +1418,22 @@ static const device_config_t voodoo_config[] = { }, #endif { - .type = -1 + .type = CONFIG_END } // clang-format on }; const device_t voodoo_device = { - "3DFX Voodoo Graphics", - "voodoo", - DEVICE_PCI, - 0, - voodoo_init, - voodoo_close, - NULL, - { NULL }, - voodoo_speed_changed, - voodoo_force_blit, - voodoo_config + .name = "3DFX Voodoo Graphics", + .internal_name = "voodoo", + .flags = DEVICE_PCI, + .local = 0, + .init = voodoo_init, + .close = voodoo_close, + .reset = NULL, + { .available = NULL }, + .speed_changed = voodoo_speed_changed, + .force_redraw = voodoo_force_blit, + .config = voodoo_config }; diff --git a/src/video/vid_voodoo_banshee.c b/src/video/vid_voodoo_banshee.c index b314cc152..48d14a5b6 100644 --- a/src/video/vid_voodoo_banshee.c +++ b/src/video/vid_voodoo_banshee.c @@ -2601,8 +2601,7 @@ static void banshee_pci_write(int func, int addr, uint8_t val, void *p) } // clang-format off -static const device_config_t banshee_sgram_config[] = -{ +static const device_config_t banshee_sgram_config[] = { { .name = "memory", .description = "Memory size", @@ -2672,12 +2671,11 @@ static const device_config_t banshee_sgram_config[] = }, #endif { - .type = -1 + .type = CONFIG_END } }; -static const device_config_t banshee_sdram_config[] = -{ +static const device_config_t banshee_sdram_config[] = { { .name = "bilinear", .description = "Bilinear filtering", @@ -2728,7 +2726,7 @@ static const device_config_t banshee_sdram_config[] = }, #endif { - .type = -1 + .type = CONFIG_END } }; // clang-format on @@ -2954,123 +2952,114 @@ static void banshee_force_redraw(void *p) banshee->svga.fullchange = changeframecount; } - -const device_t voodoo_banshee_device = -{ - "3dfx Voodoo Banshee", - "voodoo_banshee_pci", - DEVICE_PCI, - 0, - banshee_init, - banshee_close, - NULL, - { banshee_available }, - banshee_speed_changed, - banshee_force_redraw, - banshee_sgram_config +const device_t voodoo_banshee_device = { + .name = "3dfx Voodoo Banshee", + .internal_name = "voodoo_banshee_pci", + .flags = DEVICE_PCI, + .local = 0, + .init = banshee_init, + .close = banshee_close, + .reset = NULL, + { .available = banshee_available }, + .speed_changed = banshee_speed_changed, + .force_redraw = banshee_force_redraw, + banshee_sgram_config }; -const device_t creative_voodoo_banshee_device = -{ - "Creative 3D Blaster Banshee", - "ctl3d_banshee_pci", - DEVICE_PCI, - 0, - creative_banshee_init, - banshee_close, - NULL, - { creative_banshee_available }, - banshee_speed_changed, - banshee_force_redraw, - banshee_sdram_config +const device_t creative_voodoo_banshee_device = { + .name = "Creative 3D Blaster Banshee", + .internal_name = "ctl3d_banshee_pci", + .flags = DEVICE_PCI, + .local = 0, + .init = creative_banshee_init, + .close = banshee_close, + .reset = NULL, + { .available = creative_banshee_available }, + .speed_changed = banshee_speed_changed, + .force_redraw = banshee_force_redraw, + banshee_sdram_config }; -const device_t voodoo_3_2000_device = -{ - "3dfx Voodoo3 2000", - "voodoo3_2k_pci", - DEVICE_PCI, - 0, - v3_2000_init, - banshee_close, - NULL, - { v3_2000_available }, - banshee_speed_changed, - banshee_force_redraw, - banshee_sdram_config +const device_t voodoo_3_2000_device = { + .name = "3dfx Voodoo3 2000", + .internal_name = "voodoo3_2k_pci", + .flags = DEVICE_PCI, + .local = 0, + .init = v3_2000_init, + .close = banshee_close, + .reset = NULL, + { .available = v3_2000_available }, + .speed_changed = banshee_speed_changed, + .force_redraw = banshee_force_redraw, + banshee_sdram_config }; -const device_t voodoo_3_2000_agp_device = -{ - "3dfx Voodoo3 2000", - "voodoo3_2k_agp", - DEVICE_AGP, - 0, - v3_2000_agp_init, - banshee_close, - NULL, - { v3_2000_agp_available }, - banshee_speed_changed, - banshee_force_redraw, - banshee_sdram_config +const device_t voodoo_3_2000_agp_device = { + .name = "3dfx Voodoo3 2000", + .internal_name = "voodoo3_2k_agp", + .flags = DEVICE_AGP, + .local = 0, + .init = v3_2000_agp_init, + .close = banshee_close, + .reset = NULL, + { .available = v3_2000_agp_available }, + .speed_changed = banshee_speed_changed, + .force_redraw = banshee_force_redraw, + banshee_sdram_config }; -const device_t voodoo_3_2000_agp_onboard_8m_device = -{ - "3dfx Voodoo3 2000 (On-Board 8MB SGRAM)", - "voodoo3_2k_agp_onboard_8m", - DEVICE_AGP, - 8, - v3_2000_agp_onboard_init, - banshee_close, - NULL, - { NULL }, - banshee_speed_changed, - banshee_force_redraw, - banshee_sdram_config +const device_t voodoo_3_2000_agp_onboard_8m_device = { + .name = "3dfx Voodoo3 2000 (On-Board 8MB SGRAM)", + .internal_name = "voodoo3_2k_agp_onboard_8m", + .flags = DEVICE_AGP, + .local = 8, + .init = v3_2000_agp_onboard_init, + .close = banshee_close, + .reset = NULL, + { .available = NULL }, + .speed_changed = banshee_speed_changed, + .force_redraw = banshee_force_redraw, + banshee_sdram_config }; -const device_t voodoo_3_3000_device = -{ - "3dfx Voodoo3 3000", - "voodoo3_3k_pci", - DEVICE_PCI, - 0, - v3_3000_init, - banshee_close, - NULL, - { v3_3000_available }, - banshee_speed_changed, - banshee_force_redraw, - banshee_sdram_config +const device_t voodoo_3_3000_device = { + .name = "3dfx Voodoo3 3000", + .internal_name = "voodoo3_3k_pci", + .flags = DEVICE_PCI, + .local = 0, + .init = v3_3000_init, + .close = banshee_close, + .reset = NULL, + { .available = v3_3000_available }, + .speed_changed = banshee_speed_changed, + .force_redraw = banshee_force_redraw, + banshee_sdram_config }; -const device_t voodoo_3_3000_agp_device = -{ - "3dfx Voodoo3 3000", - "voodoo3_3k_agp", - DEVICE_AGP, - 0, - v3_3000_agp_init, - banshee_close, - NULL, - { v3_3000_agp_available }, - banshee_speed_changed, - banshee_force_redraw, - banshee_sdram_config +const device_t voodoo_3_3000_agp_device = { + .name = "3dfx Voodoo3 3000", + .internal_name = "voodoo3_3k_agp", + .flags = DEVICE_AGP, + .local = 0, + .init = v3_3000_agp_init, + .close = banshee_close, + .reset = NULL, + { .available = v3_3000_agp_available }, + .speed_changed = banshee_speed_changed, + .force_redraw = banshee_force_redraw, + banshee_sdram_config }; -const device_t velocity_100_agp_device = -{ - "3dfx Velocity 100", - "velocity100_agp", - DEVICE_AGP, - 0, - velocity_100_agp_init, - banshee_close, - NULL, - { velocity_100_available }, - banshee_speed_changed, - banshee_force_redraw, - banshee_sdram_config +const device_t velocity_100_agp_device = { + .name = "3dfx Velocity 100", + .internal_name = "velocity100_agp", + .flags = DEVICE_AGP, + .local = 0, + .init = velocity_100_agp_init, + .close = banshee_close, + .reset = NULL, + { .available = velocity_100_available }, + .speed_changed = banshee_speed_changed, + .force_redraw = banshee_force_redraw, + banshee_sdram_config };