diff --git a/src/FNA3D_Driver_SDL.c b/src/FNA3D_Driver_SDL.c index 51ab9fa4..1c0a64ab 100644 --- a/src/FNA3D_Driver_SDL.c +++ b/src/FNA3D_Driver_SDL.c @@ -3999,27 +3999,28 @@ static FNA3D_Device* SDLGPU_CreateDevice( } } - if (!XNAToSDL_PresentMode( + if (!SDL_GpuClaimWindow( renderer->device, - presentationParameters->deviceWindowHandle, - presentationParameters->presentationInterval, - &desiredPresentMode + presentationParameters->deviceWindowHandle )) { - FNA3D_LogError("Failed to set suitable present mode!"); + FNA3D_LogError("Failed to claim window!"); SDL_free(renderer); SDL_free(result); return NULL; } - if (!SDL_GpuClaimWindow( + if (!XNAToSDL_PresentMode( renderer->device, - presentationParameters->deviceWindowHandle + presentationParameters->deviceWindowHandle, + presentationParameters->presentationInterval, + &desiredPresentMode )) { - FNA3D_LogError("Failed to claim window!"); + FNA3D_LogError("Failed to set suitable present mode!"); SDL_free(renderer); SDL_free(result); return NULL; } + if (!SDL_GpuSetSwapchainParameters( renderer->device, presentationParameters->deviceWindowHandle,