Make dual video card code use array

This commit is contained in:
Jasmine Iwanek
2023-02-06 04:12:46 -05:00
parent 6978f6d7d4
commit a7236a9022
31 changed files with 115 additions and 118 deletions

View File

@@ -331,7 +331,7 @@ video_reset(int card)
if ((video_get_type() != VIDEO_FLAG_TYPE_NONE) && was_reset)
return;
vid_table_log("VIDEO: reset (gfxcard=%d, internal=%d)\n",
vid_table_log("VIDEO: reset (gfxcard[0]=%d, internal=%d)\n",
card, machine_has_flags(machine, MACHINE_VIDEO) ? 1 : 0);
monitor_index_global = 0;
@@ -349,11 +349,11 @@ video_reset(int card)
if (!(card == VID_NONE)
&& !machine_has_flags(machine, MACHINE_VIDEO_ONLY)
&& gfxcard_2 != 0
&& device_is_valid(video_card_getdevice(gfxcard_2), machine)) {
&& gfxcard[1] != 0
&& device_is_valid(video_card_getdevice(gfxcard[1]), machine)) {
video_monitor_init(1);
monitor_index_global = 1;
device_add(video_cards[gfxcard_2].device);
device_add(video_cards[gfxcard[1]].device);
monitor_index_global = 0;
}