mirror of
https://github.com/libretro/RetroArch
synced 2025-04-07 13:23:32 +00:00
Set current_video_context_api for GL and Vulkan
This commit is contained in:
parent
a22131b452
commit
c8028f3150
@ -586,12 +586,13 @@ static void video_context_driver_reset(void)
|
||||
if (current_video_context.has_focus)
|
||||
video_driver_cb_has_focus = video_context_has_focus;
|
||||
|
||||
|
||||
if (current_video_context_api == GFX_CTX_NONE)
|
||||
{
|
||||
const char *video_driver = video_driver_get_ident();
|
||||
|
||||
if(string_is_equal(video_driver, "d3d10"))
|
||||
if (string_is_equal(video_driver, "d3d9"))
|
||||
current_video_context_api = GFX_CTX_DIRECT3D9_API;
|
||||
else if (string_is_equal(video_driver, "d3d10"))
|
||||
current_video_context_api = GFX_CTX_DIRECT3D10_API;
|
||||
else if (string_is_equal(video_driver, "d3d11"))
|
||||
current_video_context_api = GFX_CTX_DIRECT3D11_API;
|
||||
@ -599,6 +600,10 @@ static void video_context_driver_reset(void)
|
||||
current_video_context_api = GFX_CTX_DIRECT3D12_API;
|
||||
else if (string_is_equal(video_driver, "gx2"))
|
||||
current_video_context_api = GFX_CTX_GX2_API;
|
||||
else if (string_is_equal(video_driver, "gl"))
|
||||
current_video_context_api = GFX_CTX_OPENGL_API;
|
||||
else if (string_is_equal(video_driver, "vulkan"))
|
||||
current_video_context_api = GFX_CTX_VULKAN_API;
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user