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

Wayland scaled display issue #404

Open
dazoe opened this issue Aug 5, 2024 · 5 comments
Open

Wayland scaled display issue #404

dazoe opened this issue Aug 5, 2024 · 5 comments

Comments

@dazoe
Copy link

dazoe commented Aug 5, 2024

Display scaling on Wayland seems to cause problems.
I run with my display scaled to 110%
When running the gl41core-cube example with wayland build tag the cube renders in the lower left corner.
The x11 version looked normal.
After investigating I found out the x11 version wasn't actually normal because it was only 5% smaller.
The wayland version was scaling the frame buffer to 2x instead of just 1.1x like x11
Adding a FramebufferSizeCallback and changing setting gl.Viewport corrects the example.

Is wayland scaling to 2x instead of 1.1x intended behavior? Or is it due to upstream support?

@snoweuph
Copy link

snoweuph commented Sep 14, 2024

Had the Same Problem with GLFW before under Java.

The Scaling is on the Window Object, not the Desktop Object,

The scaling object beeing only ints Is intended, on the Window it should be the right Scaling Information though

@Cyliann
Copy link

Cyliann commented Oct 15, 2024

I have the same exact problem. My screen scaling is set to 1.25. When renderring a white screen only the left-bottom quarter is affected. The problem vanishes, when scaling is set to 1.
image

@snoweuph
Copy link

The Scaling is on the Window Object, not the Desktop Object,

The scaling object beeing only ints Is intended, on the Window it should be the right Scaling Information though

@Cyliann try this

@Cyliann
Copy link

Cyliann commented Oct 18, 2024

@Cyliann try this

Try what exactly?

@snoweuph
Copy link

snoweuph commented Oct 18, 2024

Getting the Scale of the Desktop from the Window, instead of from the Desktop object.
Thats how GLFW does it.
The Desktop Scale on the Dekstop object can't hold Fractional Scalings, the Fractional Info is on the Window Objects

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

No branches or pull requests

3 participants