diff --git a/UnleashedRecomp/cfg/config.h b/UnleashedRecomp/cfg/config.h index f391cc1d..83686050 100644 --- a/UnleashedRecomp/cfg/config.h +++ b/UnleashedRecomp/cfg/config.h @@ -35,6 +35,7 @@ public: CONFIG_DEFINE("Video", int32_t, WindowWidth, 1280); CONFIG_DEFINE("Video", int32_t, WindowHeight, 720); CONFIG_DEFINE_ENUM("Video", EWindowState, WindowState, EWindowState::Normal); + CONFIG_DEFINE_ENUM_LOCALISED("Video", EAspectRatio, AspectRatio, EAspectRatio::Auto); CONFIG_DEFINE_CALLBACK("Video", float, ResolutionScale, 1.0f, { diff --git a/UnleashedRecomp/cfg/config_detail.h b/UnleashedRecomp/cfg/config_detail.h index 8c55f7e8..98f4be1e 100644 --- a/UnleashedRecomp/cfg/config_detail.h +++ b/UnleashedRecomp/cfg/config_detail.h @@ -108,6 +108,20 @@ CONFIG_DEFINE_ENUM_TEMPLATE(EWindowState) { "Maximized", EWindowState::Maximised } }; +enum class EAspectRatio : uint32_t +{ + Auto, + Square, + Widescreen +}; + +CONFIG_DEFINE_ENUM_TEMPLATE(EAspectRatio) +{ + { "Auto", EAspectRatio::Auto }, + { "4:3", EAspectRatio::Square }, + { "16:9", EAspectRatio::Widescreen } +}; + enum class EAntiAliasing : uint32_t { None = 0, diff --git a/UnleashedRecomp/locale/config_locale.h b/UnleashedRecomp/locale/config_locale.h index fd61b596..95aa5db3 100644 --- a/UnleashedRecomp/locale/config_locale.h +++ b/UnleashedRecomp/locale/config_locale.h @@ -192,9 +192,19 @@ CONFIG_DEFINE_LOCALE(BattleTheme) { ELanguage::English, { "Battle Theme", "Play the Werehog battle theme during combat.\n\nThis option will apply the next time you're in combat." } } }; -CONFIG_DEFINE_LOCALE(WindowSize) +CONFIG_DEFINE_LOCALE(AspectRatio) { - { ELanguage::English, { "Window Size", "Adjust the size of the game window in windowed mode." } } + { ELanguage::English, { "Aspect Ratio", "Change the aspect ratio." } } +}; + +CONFIG_DEFINE_ENUM_LOCALE(EAspectRatio) +{ + { + ELanguage::English, + { + { EAspectRatio::Auto, { "AUTO", "Auto: the aspect ratio will dynamically adjust to the window size." } } + } + } }; CONFIG_DEFINE_LOCALE(ResolutionScale) diff --git a/UnleashedRecomp/locale/locale.h b/UnleashedRecomp/locale/locale.h index 16988494..6e3a4253 100644 --- a/UnleashedRecomp/locale/locale.h +++ b/UnleashedRecomp/locale/locale.h @@ -36,6 +36,18 @@ inline static std::unordered_map