diff --git a/CMakeLists.txt b/CMakeLists.txt index 04f0c9e9..eef143b8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -65,7 +65,7 @@ option(CURL_SUPPORT "cURL support" ON) option(OPENAL_SUPPORT "OpenAL support" ON) option(SYSTEMWIDE_SUPPORT "Enable systemwide installation of game assets" OFF) option(SDL3_SUPPORT "Build against SDL 3 instead of SDL2" OFF) -option(GL1_RENDERER "Build the GL3 renderer" ON) +option(GL1_RENDERER "Build the GL1 renderer" ON) option(GL3_RENDERER "Build the GL3 renderer" ON) option(GLES1_RENDERER "Build the GLES1 renderer" OFF) option(GLES3_RENDERER "Build the GLES3 renderer" ON) @@ -169,10 +169,10 @@ unset(cpu) # Systemwide installation of game assets. if(${SYSTEMWIDE_SUPPORT}) - add_definitions(-DSYSTEMWIDE) - if(NOT ${SYSTEMDIR} STREQUAL "") - add_definitions(-DSYSTEMDIR="${SYSTEMDIR}") - endif() + add_definitions(-DSYSTEMWIDE) + if(NOT ${SYSTEMDIR} STREQUAL "") + add_definitions(-DSYSTEMDIR="${SYSTEMDIR}") + endif() endif() # We need to pass some options to minizip / unzip. @@ -195,11 +195,11 @@ else() endif() if(GL1_RENDERER) - # We need an OpenGL implementation. - set(OpenGL_GL_PREFERENCE GLVND) - find_package(OpenGL REQUIRED) - list(APPEND yquake2IncludeDirectories ${OPENGL_INCLUDE_DIR}) - list(APPEND yquake2OpenGLLinkerFlags ${OPENGL_LIBRARIES}) + # We need an OpenGL implementation. + set(OpenGL_GL_PREFERENCE GLVND) + find_package(OpenGL REQUIRED) + list(APPEND yquake2IncludeDirectories ${OPENGL_INCLUDE_DIR}) + list(APPEND yquake2OpenGLLinkerFlags ${OPENGL_LIBRARIES}) endif() # backtrace lookup @@ -260,7 +260,7 @@ else() list(APPEND yquake2LinkerFlags "-rdynamic") else() list(APPEND yquake2LinkerFlags "-lnetwork") - set(CMAKE_POSITION_INDEPENDENT_CODE ON) + set(CMAKE_POSITION_INDEPENDENT_CODE ON) endif() if (${CMAKE_SYSTEM_NAME} MATCHES "SunOS") list(APPEND yquake2LinkerFlags "-lsocket -lnsl") diff --git a/src/client/refresh/soft/sw_main.c b/src/client/refresh/soft/sw_main.c index ea4e8c77..2240830b 100644 --- a/src/client/refresh/soft/sw_main.c +++ b/src/client/refresh/soft/sw_main.c @@ -1854,9 +1854,9 @@ GetRefAPI(refimport_t imp) refexport.EndWorldRenderpass = RE_EndWorldRenderpass; refexport.EndFrame = RE_EndFrame; - // Tell the client that we're unsing the + // Tell the client that we're unsing the // new renderer restart API. - ri.Vid_RequestRestart(RESTART_NO); + ri.Vid_RequestRestart(RESTART_NO); Swap_Init (); @@ -1909,10 +1909,10 @@ RE_InitContext(void *win) SDL_SetRenderVSync(renderer, 1); #else renderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_ACCELERATED | SDL_RENDERER_PRESENTVSYNC); - if(!renderer) - { - renderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_SOFTWARE | SDL_RENDERER_PRESENTVSYNC); - } + if(!renderer) + { + renderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_SOFTWARE | SDL_RENDERER_PRESENTVSYNC); + } #endif } else @@ -1921,10 +1921,10 @@ RE_InitContext(void *win) renderer = SDL_CreateRenderer(window, NULL); #else renderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_ACCELERATED); - if(!renderer) - { - renderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_SOFTWARE); - } + if(!renderer) + { + renderer = SDL_CreateRenderer(window, -1, SDL_RENDERER_SOFTWARE); + } #endif } if(!renderer) { diff --git a/src/client/vid/glimp_sdl2.c b/src/client/vid/glimp_sdl2.c index 80b05938..2edfb831 100644 --- a/src/client/vid/glimp_sdl2.c +++ b/src/client/vid/glimp_sdl2.c @@ -376,7 +376,7 @@ ShutdownGraphics(void) } else { SDL_GetWindowPosition(window, - &last_position_x, &last_position_y); + &last_position_x, &last_position_y); } /* cleanly ungrab input (needs window) */ @@ -640,8 +640,7 @@ GLimp_InitGraphics(int fullscreen, int *pwidth, int *pheight) Com_Printf("Real display mode: %ix%i@%i\n", mode.w, mode.h, mode.refresh_rate); } - - /* Initialize rendering context. */ + /* Initialize rendering context. */ if (!re.InitContext(window)) { /* InitContext() should have logged an error. */