Allow S3 emulation to have 16MB of video RAM, though the register values for now will still report 8MB for backwards compatibility

This commit is contained in:
Jonathan Campbell
2019-12-28 17:56:07 -08:00
parent f8aebf9532
commit cd53cec99a
2 changed files with 5 additions and 2 deletions

View File

@@ -1148,7 +1148,7 @@ void DOSBOX_SetupConfigSections(void) {
"what you want. Recommended values -1, 0 to 2000.");
Pint = secprop->Add_int("vmemsize", Property::Changeable::WhenIdle,-1);
Pint->SetMinMax(-1,8);
Pint->SetMinMax(-1,16);
Pint->Set_help(
"Amount of video memory in megabytes.\n"
" The maximum resolution and color depth the svga_s3 will be able to display\n"

View File

@@ -578,9 +578,12 @@ void SVGA_Setup_S3Trio(void) {
} else if (vga.mem.memsize < 8192*1024) { // Trio64 supported only up to 4M
vga.mem.memsize = 4096*1024;
vga.s3.reg_36 = 0x1a; // 4mb fast page mode
} else { // 8M
} else if (vga.mem.memsize < 16384*1024) { // 8M
vga.mem.memsize = 8192*1024;
vga.s3.reg_36 = 0x7a; // 8mb fast page mode
} else { // HACK: 16MB mode, with value not supported by actual hardware
vga.mem.memsize = 16384*1024; // FIXME: This breaks the cursor in Windows 3.1, though Windows 95 has no problem with it
vga.s3.reg_36 = 0x7a; // 8mb fast page mode
}
// S3 ROM signature