mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-06-15 02:37:52 +00:00
Improved error information when renderer creation fails
On Android, if you create a window with SDL_WINDOW_OPENGL, you can't create a Vulkan surface. The error message has been improved to reflect this, and the error is propagated back up to the application. Also added warn level logging if the renderer couldn't be created.
This commit is contained in:
parent
edf5f9ec5c
commit
3316dde0c2
3 changed files with 16 additions and 3 deletions
|
|
@ -1812,7 +1812,6 @@ static VkResult VULKAN_CreateDeviceResources(SDL_Renderer *renderer, SDL_Propert
|
|||
} else {
|
||||
if (!SDL_Vulkan_CreateSurface(renderer->window, rendererData->instance, NULL, &rendererData->surface)) {
|
||||
VULKAN_DestroyAll(renderer);
|
||||
SET_ERROR_MESSAGE("Vulkan_CreateSurface() failed");
|
||||
return VK_ERROR_UNKNOWN;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue