Skip to content

Commit

Permalink
calc_scale_factor_scaler: ternary back to if else
Browse files Browse the repository at this point in the history
  • Loading branch information
sharkautarch committed Sep 3, 2024
1 parent a8b9435 commit 3d5224d
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/steamcompmgr.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1351,7 +1351,12 @@ glm::vec2 calc_scale_factor_scaler(float sourceWidth, float sourceHeight)
return ratios * outputRatio;
}

auto out_scale = glm::vec2{g_upscaleScaler != GamescopeUpscaleScaler::FILL ? glm::min(ratios.x, ratios.y) : glm::max(ratios.x, ratios.y)};
glm::vec2 out_scale;
if (g_upscaleScaler != GamescopeUpscaleScaler::FILL) {
out_scale = glm::vec2{ glm::min(ratios.x, ratios.y) };
} else {
out_scale = glm::vec2{ glm::max(ratios.x, ratios.y) };
}

if (g_upscaleScaler == GamescopeUpscaleScaler::AUTO)
{
Expand Down

0 comments on commit 3d5224d

Please sign in to comment.