-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
[rcore_desktop] Upon entering fullscreen, uses original window size #3929
Comments
It seems that the actual resizing of the window contents is done in the WindowSizeCallback after the first call to EndDrawing() in the game loop. raylib/src/platforms/rcore_desktop.c Line 1625 in 2e77443
Commenting this line solved the issue for me, but I presume is there for a reason. |
That's really strange. To me this definitely doesn't seem like expected behavior. |
There should probably be a comment there explaining that reason... I don't know at the moment... |
I ran the sample code under msys2 and Fedora. I found the reason is when |
@archewashi Thanks for the further investigation and provided details! It seems a platform-dependant issue, that's usually difficult to address... |
I guess the reason is the glfw commands to X11 are asynchronous (X11 handle commands asynchronously). |
I'm running into the same issue (coincidentally with the same environment specs!), and I've found using |
maybe it is ok to update the values of |
Issue description
Upon running the procedure
ToggleFullscreen()
, raylib reports "GetScreenWidth()" and "GetScreenHeight()" as values set beforeSetWindowSize(x, y)
. However, withoutToggleFullscreen()
, the original values are kept for one frame then immediately restored to correct full resolution.Environment
Platform backend: DESKTOP (GLFW)
OS: Fedora 39 x86_64
Desktop: Gnome X11
OpenGL version: 4.6
GPU: Integrated
Issue Screenshot
Screencast from 2024-04-22 18-22-46.webm
Screencast from 2024-04-22 18-26-19.webm
Code Example
The text was updated successfully, but these errors were encountered: