From f11ce3b1dd5773cd885a1782288ec8b322dab9ec Mon Sep 17 00:00:00 2001 From: Aki Date: Sat, 12 Feb 2022 21:08:34 +0100 Subject: Added some modern screen resolutions and increased the defaults a bit --- Stars45/Starshatter.cpp | 4 ++-- Stars45/VidDlg.cpp | 31 +++++++++++++++++++++++++++++++ Stars45/VideoSettings.cpp | 8 ++++---- 3 files changed, 37 insertions(+), 6 deletions(-) (limited to 'Stars45') diff --git a/Stars45/Starshatter.cpp b/Stars45/Starshatter.cpp index 3077aca..c859741 100644 --- a/Stars45/Starshatter.cpp +++ b/Stars45/Starshatter.cpp @@ -2393,8 +2393,8 @@ void Starshatter::LoadVideoConfig(const char* filename) { // set up defaults: - int screen_width = 1024; - int screen_height = 768; + int screen_width = 1280; + int screen_height = 720; int screen_depth = 32; int terrain_detail_level = 3; bool shadows_enabled = true; diff --git a/Stars45/VidDlg.cpp b/Stars45/VidDlg.cpp index e7bdc09..b7e3505 100644 --- a/Stars45/VidDlg.cpp +++ b/Stars45/VidDlg.cpp @@ -345,6 +345,10 @@ VidDlg::Apply() w = 1280; h = 1024; } + else if (strstr(mode_desc, "1366 x 768")) { + w = 1366; + h = 768; + } else if (strstr(mode_desc, "1440 x 900")) { w = 1440; h = 900; @@ -357,6 +361,22 @@ VidDlg::Apply() w = 1600; h = 1200; } + else if (strstr(mode_desc, "1680 x 1050")) { + w = 1680; + h = 1050; + } + else if (strstr(mode_desc, "1920 x 1080")) { + w = 1920; + h = 1080; + } + else if (strstr(mode_desc, "2560 x 1080")) { + w = 2560; + h = 1080; + } + else if (strstr(mode_desc, "3440 x 1440")) { + w = 3440; + h = 1440; + } if (strstr(mode_desc, "x 16")) d = 16; @@ -488,6 +508,9 @@ VidDlg::BuildModeList() if (Game::DisplayModeSupported(1280,1024, 16)) mode->AddItem("1280 x 1024 x 16"); if (Game::DisplayModeSupported(1280,1024, 32)) mode->AddItem("1280 x 1024 x 32"); + if (Game::DisplayModeSupported(1366, 768, 16)) mode->AddItem("1366 x 768 x 16"); + if (Game::DisplayModeSupported(1366, 768, 32)) mode->AddItem("1366 x 768 x 32"); + if (Game::DisplayModeSupported(1440, 900, 16)) mode->AddItem("1440 x 900 x 16"); if (Game::DisplayModeSupported(1440, 900, 32)) mode->AddItem("1440 x 900 x 32"); @@ -500,6 +523,9 @@ VidDlg::BuildModeList() if (Game::DisplayModeSupported(1680,1050, 16)) mode->AddItem("1680 x 1050 x 16"); if (Game::DisplayModeSupported(1680,1050, 32)) mode->AddItem("1680 x 1050 x 32"); + if (Game::DisplayModeSupported(1920,1080, 16)) mode->AddItem("1920 x 1080 x 16"); + if (Game::DisplayModeSupported(1920,1080, 32)) mode->AddItem("1920 x 1080 x 32"); + Video* video = Game::GetVideo(); if (stars && video) { @@ -516,6 +542,7 @@ VidDlg::BuildModeList() else strcpy_s(mode_desc, "1280 x 1024 x "); break; + case 1366: strcpy_s(mode_desc, "1366 x 768 x "); break; case 1440: strcpy_s(mode_desc, "1440 x 900 x "); break; case 1600: if (video->Height() < 1000) @@ -523,6 +550,10 @@ VidDlg::BuildModeList() else strcpy_s(mode_desc, "1600 x 1200 x "); break; + case 1680: strcpy_s(mode_desc, "1680 x 1050 x "); break; + case 1920: strcpy_s(mode_desc, "1920 x 1080 x "); break; + case 2560: strcpy_s(mode_desc, "2560 x 1080 x "); break; + case 3440: strcpy_s(mode_desc, "3440 x 1440 x "); break; } switch (video->Depth()) { diff --git a/Stars45/VideoSettings.cpp b/Stars45/VideoSettings.cpp index 995358c..9700901 100644 --- a/Stars45/VideoSettings.cpp +++ b/Stars45/VideoSettings.cpp @@ -48,13 +48,13 @@ VideoSettings::VideoSettings() fullscreen_mode.refresh = 75; fullscreen_mode.format = VideoMode::FMT_X8R8G8B8; - windowed_mode.width = 800; - windowed_mode.height = 600; + windowed_mode.width = 1280; + windowed_mode.height = 720; windowed_mode.refresh = 0; windowed_mode.format = VideoMode::FMT_NONE; - window_width = 800; - window_height = 600; + window_width = 1280; + window_height = 720; is_windowed = false; use_effects = true; -- cgit v1.1