Skip to content

Commit

Permalink
fixed fsr fov sliders
Browse files Browse the repository at this point in the history
  • Loading branch information
cdozdil committed May 18, 2024
1 parent 9814565 commit 53da36c
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions OptiScaler/imgui/imgui_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -920,9 +920,15 @@ class ImGuiCommon
vfov = Config::Instance()->FsrVerticalFov.value_or(60.0f);
hfov = Config::Instance()->FsrHorizontalFov.value_or(90.0f);

if (useVFov && !Config::Instance()->FsrVerticalFov.has_value())
Config::Instance()->FsrVerticalFov = vfov;
else if (!useVFov && !Config::Instance()->FsrHorizontalFov.has_value())
Config::Instance()->FsrHorizontalFov = hfov;

if (ImGui::RadioButton("Use Vert. Fov", useVFov))
{
Config::Instance()->FsrHorizontalFov.reset();
Config::Instance()->FsrVerticalFov = vfov;
useVFov = true;
}

Expand All @@ -931,6 +937,7 @@ class ImGuiCommon
if (ImGui::RadioButton("Use Horz. Fov", !useVFov))
{
Config::Instance()->FsrVerticalFov.reset();
Config::Instance()->FsrHorizontalFov = hfov;
useVFov = false;
}

Expand Down

0 comments on commit 53da36c

Please sign in to comment.