mirror of https://github.com/OpenTTD/OpenTTD
Merge dce3be56f1
into a46a3a97f3
commit
fbfee72678
|
@ -118,7 +118,7 @@ std::optional<std::string_view> VideoDriver_SDL_OpenGL::AllocateContext()
|
||||||
}
|
}
|
||||||
|
|
||||||
this->gl_context = SDL_GL_CreateContext(this->sdl_window);
|
this->gl_context = SDL_GL_CreateContext(this->sdl_window);
|
||||||
if (this->gl_context == nullptr) return "SDL2: Can't active GL context";
|
if (this->gl_context == nullptr) return "SDL2: Can't activate GL context";
|
||||||
|
|
||||||
ToggleVsync(_video_vsync);
|
ToggleVsync(_video_vsync);
|
||||||
|
|
||||||
|
|
|
@ -1507,7 +1507,7 @@ std::optional<std::string_view> VideoDriver_Win32OpenGL::AllocateContext()
|
||||||
rc = wglCreateContext(this->dc);
|
rc = wglCreateContext(this->dc);
|
||||||
if (rc == nullptr) return "Can't create OpenGL context";
|
if (rc == nullptr) return "Can't create OpenGL context";
|
||||||
}
|
}
|
||||||
if (!wglMakeCurrent(this->dc, rc)) return "Can't active GL context";
|
if (!wglMakeCurrent(this->dc, rc)) return "Can't activate GL context";
|
||||||
|
|
||||||
this->ToggleVsync(_video_vsync);
|
this->ToggleVsync(_video_vsync);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue