mirror of
https://github.com/86Box/86Box.git
synced 2026-02-22 01:25:33 -07:00
Enhance VGA pass-through handling in vid_voodoo.c
Added logic to handle VGA pass-through state changes and mark lines dirty for refresh.
This commit is contained in:
@@ -516,6 +516,7 @@ voodoo_writel(uint32_t addr, uint32_t val, void *priv)
|
||||
break;
|
||||
case SST_fbiInit0:
|
||||
if (voodoo->initEnable & 0x01) {
|
||||
int old_vga_pass = voodoo->fbiInit0 & FBIINIT0_VGA_PASS;
|
||||
voodoo->fbiInit0 = val;
|
||||
thread_wait_mutex(voodoo->force_blit_mutex);
|
||||
voodoo->can_blit = (voodoo->fbiInit0 & FBIINIT0_VGA_PASS) ? 1 : 0;
|
||||
@@ -523,6 +524,10 @@ voodoo_writel(uint32_t addr, uint32_t val, void *priv)
|
||||
voodoo->force_blit_count = 0;
|
||||
thread_release_mutex(voodoo->force_blit_mutex);
|
||||
|
||||
/* When VGA pass-through becomes active, mark all lines dirty to force full refresh */
|
||||
if (!old_vga_pass && (val & FBIINIT0_VGA_PASS))
|
||||
memset(voodoo->dirty_line, 1, sizeof(voodoo->dirty_line));
|
||||
|
||||
if (voodoo->set->nr_cards == 2)
|
||||
svga_set_override(voodoo->svga, (voodoo->set->voodoos[0]->fbiInit0 | voodoo->set->voodoos[1]->fbiInit0) & 1);
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user