-
-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Open
Labels
help needed - please!I need help with this issueI need help with this issuewindowingIssues about the window systemIssues about the window system
Description
Issue description
Upon running the procedure ToggleFullscreen(), raylib reports "GetScreenWidth()" and "GetScreenHeight()" as values set before SetWindowSize(x, y). However, without ToggleFullscreen(), 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
#include <stdio.h>
#include <raylib.h>
int main(void)
{
InitWindow(1, 1, "Application");
int display = GetCurrentMonitor();
SetWindowSize(GetMonitorWidth(display), GetMonitorHeight(display));
ToggleFullscreen();
while (!WindowShouldClose()) {
BeginDrawing();
DrawRectangle(0, 0, GetMonitorWidth(display), GetMonitorHeight(display), RAYWHITE);
printf("%d %d\n", GetScreenWidth(), GetScreenHeight());
DrawRectangle(0, 0, GetScreenWidth() / 2, GetScreenHeight() / 2, RED);
EndDrawing();
}
CloseWindow();
return 0;
}Metadata
Metadata
Assignees
Labels
help needed - please!I need help with this issueI need help with this issuewindowingIssues about the window systemIssues about the window system