Repository navigation
Fix widescreen HUD scaling and script aspect ratio alignment - #5563
Open
MohabCodeX wants to merge 4 commits into
Open
MohabCodeX wants to merge 4 commits into
MohabCodeX wants to merge 4 commits into
Conversation
Keep PR 1 focused on HUD scaling and horizontal aspect-ratio conversion changes without extra test boilerplate.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #848
Closes #333
Instead of stretching HUD height on widescreen displays, this keeps vertical proportions fixed and scales the HUD horizontally to fit the screen's aspect ratio. It also resolves the HUD scaling part of #2753 so HUD elements no longer blow up vertically on ultrawide monitors like 32:9.
Weapon icons, centered vehicle and area names, and crosshairs now stay properly proportioned and positioned alongside the radar and bars across 16:9, 21:9, and 32:9 resolutions without height inflation workarounds.
Aspect ratio adjustment for DX drawing and GUI positioning (
dxSetAspectRatioAdjustmentEnabledandguiSetPosition) now converts horizontal coordinates rather than vertical ones so custom HUD scripts and resources likecustomblipsstay lined up with the radar and right-side HUD. When the HUD match aspect ratio setting is disabled, scripts written for non-4:3 aspect ratios are still adjusted cleanly against the 4:3 HUD, and non-positive or non-finite source ratios are rejected.