Screen: afegit flag per iniciar la finestra en mode de pantalla completa
This commit is contained in:
@@ -340,11 +340,16 @@ bool Screen::initSDLVideo()
|
||||
}
|
||||
|
||||
// Crear ventana
|
||||
SDL_WindowFlags window_flags = SDL_WINDOW_OPENGL;
|
||||
if (Options::video.fullscreen)
|
||||
{
|
||||
window_flags |= SDL_WINDOW_FULLSCREEN;
|
||||
}
|
||||
window_ = SDL_CreateWindow(
|
||||
Options::window.caption.c_str(),
|
||||
param.game.width * Options::window.size,
|
||||
param.game.height * Options::window.size,
|
||||
SDL_WINDOW_OPENGL);
|
||||
window_flags);
|
||||
|
||||
if (!window_)
|
||||
{
|
||||
@@ -373,7 +378,7 @@ bool Screen::initSDLVideo()
|
||||
SDL_SetRenderLogicalPresentation(renderer_, param.game.width, param.game.height, Options::video.integer_scale ? SDL_LOGICAL_PRESENTATION_INTEGER_SCALE : SDL_LOGICAL_PRESENTATION_LETTERBOX);
|
||||
SDL_SetRenderDrawBlendMode(renderer_, SDL_BLENDMODE_BLEND);
|
||||
SDL_SetRenderVSync(renderer_, Options::video.v_sync ? 1 : SDL_RENDERER_VSYNC_DISABLED);
|
||||
SDL_SetWindowFullscreen(window_, Options::video.fullscreen);
|
||||
// SDL_SetWindowFullscreen(window_, Options::video.fullscreen);
|
||||
|
||||
SDL_LogInfo(SDL_LOG_CATEGORY_APPLICATION, "SDL Video initialized successfully.");
|
||||
return true;
|
||||
|
||||
Reference in New Issue
Block a user