diff --git a/src/platforms/rcore_desktop_rgfw.c b/src/platforms/rcore_desktop_rgfw.c index 987cac560..1cb38ff61 100644 --- a/src/platforms/rcore_desktop_rgfw.c +++ b/src/platforms/rcore_desktop_rgfw.c @@ -810,8 +810,8 @@ void SetWindowSize(int width, int height) RGFW_monitor* currentMonitor = RGFW_window_getMonitor(platform.window); CORE.Window.screenScale = MatrixScale(currentMonitor->pixelRatio, currentMonitor->pixelRatio, 1.0f); - CORE.Window.render.width = CORE.Window.screen.width * currentMonitor->pixelRatio; - CORE.Window.render.height = CORE.Window.screen.height * currentMonitor->pixelRatio; + CORE.Window.render.width = CORE.Window.screen.width*currentMonitor->pixelRatio; + CORE.Window.render.height = CORE.Window.screen.height*currentMonitor->pixelRatio; CORE.Window.currentFbo.width = CORE.Window.render.width; CORE.Window.currentFbo.height = CORE.Window.render.height; #else @@ -1139,9 +1139,9 @@ void SwapScreenBuffer(void) #if defined(__APPLE__) unsigned char temp = 0; unsigned char *p = NULL; - for (int i = 0; i < (platform.surfaceWidth * platform.surfaceHeight); i += 1) + for (int i = 0; i < (platform.surfaceWidth*platform.surfaceHeight); i += 1) { - p = platform.surfacePixels + (i * 4); + p = platform.surfacePixels + (i*4); temp = p[0]; p[0] = p[2]; p[2] = temp; @@ -1357,13 +1357,13 @@ void PollInputEvents(void) if (FLAG_IS_SET(CORE.Window.flags, FLAG_WINDOW_HIGHDPI)) { RGFW_monitor* currentMonitor = RGFW_window_getMonitor(platform.window); - SetupViewport(platform.window->w * currentMonitor->pixelRatio, platform.window->h * currentMonitor->pixelRatio); + SetupViewport(platform.window->w*currentMonitor->pixelRatio, platform.window->h*currentMonitor->pixelRatio); CORE.Window.screenScale = MatrixScale(currentMonitor->pixelRatio, currentMonitor->pixelRatio, 1.0f); CORE.Window.screen.width = platform.window->w; CORE.Window.screen.height = platform.window->h; - CORE.Window.render.width = CORE.Window.screen.width * currentMonitor->pixelRatio; - CORE.Window.render.height = CORE.Window.screen.height * currentMonitor->pixelRatio; + CORE.Window.render.width = CORE.Window.screen.width*currentMonitor->pixelRatio; + CORE.Window.render.height = CORE.Window.screen.height*currentMonitor->pixelRatio; } else { @@ -1406,10 +1406,10 @@ void PollInputEvents(void) #if defined(__APPLE__) RGFW_monitor* currentMonitor = RGFW_window_getMonitor(platform.window); CORE.Window.screenScale = MatrixScale(currentMonitor->pixelRatio, currentMonitor->pixelRatio, 1.0f); - SetupViewport(platform.window->w * currentMonitor->pixelRatio, platform.window->h * currentMonitor->pixelRatio); + SetupViewport(platform.window->w*currentMonitor->pixelRatio, platform.window->h*currentMonitor->pixelRatio); - CORE.Window.render.width = CORE.Window.screen.width * currentMonitor->pixelRatio; - CORE.Window.render.height = CORE.Window.screen.height * currentMonitor->pixelRatio; + CORE.Window.render.width = CORE.Window.screen.width*currentMonitor->pixelRatio; + CORE.Window.render.height = CORE.Window.screen.height*currentMonitor->pixelRatio; CORE.Window.currentFbo.width = CORE.Window.render.width; CORE.Window.currentFbo.height = CORE.Window.render.height; #endif @@ -1427,7 +1427,7 @@ void PollInputEvents(void) if (platform.surfacePixels != NULL) { RL_FREE(platform.surfacePixels); - platform.surfacePixels = RL_MALLOC(platform.surfaceWidth * platform.surfaceHeight * 4); + platform.surfacePixels = RL_MALLOC(platform.surfaceWidth*platform.surfaceHeight*4); } if (platform.surface != NULL) @@ -1743,8 +1743,8 @@ int InitPlatform(void) if (FLAG_IS_SET(CORE.Window.flags, FLAG_WINDOW_HIGHDPI)) { #if !defined(__APPLE__) - CORE.Window.screen.width = CORE.Window.screen.width * GetWindowScaleDPI().x; - CORE.Window.screen.height = CORE.Window.screen.height * GetWindowScaleDPI().y; + CORE.Window.screen.width = CORE.Window.screen.width*GetWindowScaleDPI().x; + CORE.Window.screen.height = CORE.Window.screen.height*GetWindowScaleDPI().y; #endif } @@ -1828,8 +1828,8 @@ int InitPlatform(void) RGFW_monitor* currentMonitor = RGFW_window_getMonitor(platform.window); CORE.Window.screenScale = MatrixScale(currentMonitor->pixelRatio, currentMonitor->pixelRatio, 1.0f); - CORE.Window.render.width = CORE.Window.screen.width * currentMonitor->pixelRatio; - CORE.Window.render.height = CORE.Window.screen.height * currentMonitor->pixelRatio; + CORE.Window.render.width = CORE.Window.screen.width*currentMonitor->pixelRatio; + CORE.Window.render.height = CORE.Window.screen.height*currentMonitor->pixelRatio; CORE.Window.currentFbo.width = CORE.Window.render.width; CORE.Window.currentFbo.height = CORE.Window.render.height; #else @@ -1846,8 +1846,8 @@ int InitPlatform(void) RGFW_monitor* currentMonitor = RGFW_window_getMonitor(platform.window); CORE.Window.screenScale = MatrixScale(currentMonitor->pixelRatio, currentMonitor->pixelRatio, 1.0f); - CORE.Window.render.width = CORE.Window.screen.width * currentMonitor->pixelRatio; - CORE.Window.render.height = CORE.Window.screen.height * currentMonitor->pixelRatio; + CORE.Window.render.width = CORE.Window.screen.width*currentMonitor->pixelRatio; + CORE.Window.render.height = CORE.Window.screen.height*currentMonitor->pixelRatio; CORE.Window.currentFbo.width = CORE.Window.render.width; CORE.Window.currentFbo.height = CORE.Window.render.height; #endif @@ -1855,7 +1855,7 @@ int InitPlatform(void) platform.surfaceWidth = CORE.Window.currentFbo.width; platform.surfaceHeight = CORE.Window.currentFbo.height; - platform.surfacePixels = RL_MALLOC(platform.surfaceWidth * platform.surfaceHeight * 4); + platform.surfacePixels = RL_MALLOC(platform.surfaceWidth*platform.surfaceHeight*4); if (platform.surfacePixels == NULL) { TRACELOG(LOG_FATAL, "PLATFORM: Failed to initialize software pixel buffer");