Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UI: Round wave coords to prevent gaps #18210

Merged
merged 1 commit into from
Sep 23, 2023

Conversation

unknownbrackets
Copy link
Collaborator

Fixes #18178. Should work fine until we hit 16000K resolutions. But by then hopefully no one will be able to notice the nanometer wide gaps.

-[Unknown]

@hrydgard hrydgard added this to the v1.16.4 milestone Sep 23, 2023
@hrydgard
Copy link
Owner

Think it can be solved without rounding - but that would require rewriting it have the rect function take x1 and x2 instead of x and width. This is fine.

@unknownbrackets
Copy link
Collaborator Author

Well, just adding in the loop instead of multiplying is enough to fix the one observed case, but I was worried there'd be some annoying overlap or gap scenario still. Although this does round to dp. But I think it's the safest way to ensure no gaps or overlap.

-[Unknown]

@hrydgard hrydgard merged commit c4ad324 into hrydgard:master Sep 23, 2023
18 checks passed
@unknownbrackets unknownbrackets deleted the ui-waves branch September 23, 2023 21:35
t *= speed;

float stepx = x;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hm, I think this x input here shouldn't be used... accidentally uses the focus position.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

A vertical line shows up in the main menu when using SDL Vulkan
2 participants