From 269e402a335e9db0f7a48bcf1fd3ab127df1ccab Mon Sep 17 00:00:00 2001 From: Alug Date: Mon, 8 Sep 2025 19:33:46 +0200 Subject: [PATCH] parentheses hell --- src/hardware/r_opengl/r_opengl.c | 26 ++++++++++---------------- 1 file changed, 10 insertions(+), 16 deletions(-) diff --git a/src/hardware/r_opengl/r_opengl.c b/src/hardware/r_opengl/r_opengl.c index 2cb7facaf..fd0e2760c 100644 --- a/src/hardware/r_opengl/r_opengl.c +++ b/src/hardware/r_opengl/r_opengl.c @@ -3127,8 +3127,8 @@ void GL_PostImgRedraw(float points[SCREENVERTS][SCREENVERTS][2]) return; // X/Y stretch fix for all resolutions(!) - xfix = (float)(screen_texsizew)/((float)((screen_width)/(float)(SCREENVERTS-1))); - yfix = (float)(screen_texsizeh)/((float)((screen_height)/(float)(SCREENVERTS-1))); + xfix = (float)screen_texsizew/((float)(screen_width/(float)(SCREENVERTS-1))); + yfix = (float)screen_texsizeh/((float)(screen_height/(float)(SCREENVERTS-1))); pglDisable(GL_DEPTH_TEST); pglDisable(GL_BLEND); @@ -3215,12 +3215,9 @@ void GL_DrawScreenTexture(int tex, FSurfaceInfo *surf, FBITFIELD polyflags) if (gl_enable_screen_textures != 2) return; - xfix = 1/((float)(screen_texsizew)/((float)((screen_width)))); - yfix = 1/((float)(screen_texsizeh)/((float)((screen_height)))); + xfix = 1/((float)screen_texsizew/(float)screen_width); + yfix = 1/((float)screen_texsizeh/(float)screen_height); - // const float screenVerts[12] - - // float fix[8]; fix[0] = 0.0f; fix[1] = 0.0f; fix[2] = 0.0f; @@ -3274,12 +3271,9 @@ void GL_DoScreenWipe(int wipeStart, int wipeEnd) if (!gl_enable_screen_textures) return; - xfix = 1/((float)(screen_texsizew)/((float)((screen_width)))); - yfix = 1/((float)(screen_texsizeh)/((float)((screen_height)))); + xfix = 1/((float)screen_texsizew/(float)screen_width); + yfix = 1/((float)screen_texsizeh/(float)screen_height); - // const float screenVerts[12] - - // float fix[8]; fix[0] = 0.0f; fix[1] = 0.0f; fix[2] = 0.0f; @@ -3349,8 +3343,8 @@ void GL_RenderVhsEffect(fixed_t upbary, fixed_t downbary, UINT8 updistort, UINT8 if (gl_enable_screen_textures != 2) return; - xfix = 1/((float)(screen_texsizew)/((float)((screen_width)))); - yfix = 1/((float)(screen_texsizeh)/((float)((screen_height)))); + xfix = 1/((float)screen_texsizew/(float)screen_width); + yfix = 1/((float)screen_texsizeh/(float)screen_height); const GLfloat scrwf = (float)screen_width; const GLfloat scrwh = (float)screen_height; @@ -3479,8 +3473,8 @@ void GL_DrawScreenFinalTexture(int tex, INT32 width, INT32 height, boolean usesh if (gl_enable_screen_textures != 2) return; - xfix = 1/((float)(screen_texsizew)/((float)((screen_width)))); - yfix = 1/((float)(screen_texsizeh)/((float)((screen_height)))); + xfix = 1/((float)screen_texsizew/(float)screen_width); + yfix = 1/((float)screen_texsizeh/(float)screen_height); origaspect = (float)screen_width / screen_height; newaspect = (float)width / height;