mirror of https://github.com/mgba-emu/mgba.git
Fix fullscreen initialization
This commit is contained in:
parent
0386d41b40
commit
084f0f037e
|
@ -139,7 +139,6 @@ static int _GBASDLInit(struct GLSoftwareRenderer* renderer) {
|
|||
SDL_GL_CreateContext(renderer->window);
|
||||
SDL_GetWindowSize(renderer->window, &renderer->viewportWidth, &renderer->viewportHeight);
|
||||
renderer->events.window = renderer->window;
|
||||
renderer->events.fullscreen = 0;
|
||||
#else
|
||||
#ifdef COLOR_16_BIT
|
||||
SDL_SetVideoMode(renderer->viewportWidth, renderer->viewportHeight, 16, SDL_OPENGL);
|
||||
|
|
|
@ -67,10 +67,10 @@ int main(int argc, char** argv) {
|
|||
#if SDL_VERSION_ATLEAST(2, 0, 0)
|
||||
renderer.viewportWidth = opts.width;
|
||||
renderer.viewportHeight = opts.height;
|
||||
renderer.events.fullscreen = opts.fullscreen;
|
||||
renderer.window = SDL_CreateWindow("GBAc", SDL_WINDOWPOS_UNDEFINED, SDL_WINDOWPOS_UNDEFINED, renderer.viewportWidth, renderer.viewportHeight, SDL_WINDOW_OPENGL | (SDL_WINDOW_FULLSCREEN_DESKTOP * renderer.events.fullscreen));
|
||||
SDL_GetWindowSize(renderer.window, &renderer.viewportWidth, &renderer.viewportHeight);
|
||||
renderer.events.window = renderer.window;
|
||||
renderer.events.fullscreen = 0;
|
||||
renderer.sdlRenderer = SDL_CreateRenderer(renderer.window, -1, SDL_RENDERER_ACCELERATED | SDL_RENDERER_PRESENTVSYNC);
|
||||
#ifdef COLOR_16_BIT
|
||||
#ifdef COLOR_5_6_5
|
||||
|
|
Loading…
Reference in New Issue