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

Game scales improperly with fractional scaling enabled in Wayland #203

Open
klazoklazo opened this issue Feb 27, 2024 · 3 comments
Open
Labels
bug Something isn't working

Comments

@klazoklazo
Copy link

When enabling fractional scaling (I currently have it enabled in KDE through Wayland), the program will similarly follow the scaling options. This should not be the desired outcome since it leads to improper integer scaling ratcheting, and additional filtering. Both seemingly cannot be removed without disabling fractional scaling.

Full screenshot

image
(Game is too zoomed out for 4k, even with integer scaling)

Blown up screenshot to show undesired filtering

image
(Note the blurry text with 1x UI scale and blurry graphics with linear filtering already disabled)

@k4zmu2a k4zmu2a added the bug Something isn't working label Feb 28, 2024
@k4zmu2a
Copy link
Owner

k4zmu2a commented Feb 28, 2024

This is probably a bug, or a lack of feature. Currently there is no special code for various DPI scenarios.
I never dealt with fractional scaling before; I will look into how it works with SDL.
At this point, I can’t guaranty that I will be able to fix this issue.

@klazoklazo
Copy link
Author

That's perfectly fine! I'm glad I could at least bring this to your attention.

@Tynach
Copy link

Tynach commented May 18, 2024

This is probably just how the Dear Imgui widget toolkit works.. Even without setting any system-wide fractional scaling value (using X11 and having a DPI of 96 set globally), the text is crisp at when the 'UI Scale' option in the menus is set to 1.00, but gets blurry just like your screenshot when you set that to literally any other value.

Doesn't matter what font is set, the font is rendered at one specific size, converted to bitmap images, and then those bitmap images are what's scaled up.

Honestly, I really REALLY don't like Dear Imgui as a result of this. Sure, it's nice and easy to embed into SDL applications, and gets the job done with a low footprint, but it really doesn't work when it comes to the needs of modern font rendering.

It also doesn't support font kerning, let alone some of the advanced OpenType features required by some languages (such as conjunct forms for Indic, and required ligatures for Arabic).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants