mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-10 23:02:08 +00:00
- avoid Vulkan initialization when it's disabled in Cocoa backend
This commit is contained in:
parent
83de8ae5a0
commit
97fc3aa9a6
1 changed files with 12 additions and 12 deletions
|
@ -364,24 +364,24 @@ public:
|
|||
vulkanView.layer.backgroundColor = NSColor.blackColor.CGColor;
|
||||
|
||||
[ms_window setContentView:vulkanView];
|
||||
|
||||
try
|
||||
{
|
||||
m_vulkanDevice = new VulkanDevice();
|
||||
fb = new VulkanFrameBuffer(nullptr, fullscreen, m_vulkanDevice);
|
||||
}
|
||||
catch (std::exception const&)
|
||||
{
|
||||
ms_isVulkanEnabled = false;
|
||||
|
||||
SetupOpenGLView(ms_window);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
SetupOpenGLView(ms_window);
|
||||
}
|
||||
|
||||
try
|
||||
{
|
||||
m_vulkanDevice = new VulkanDevice();
|
||||
fb = new VulkanFrameBuffer(nullptr, fullscreen, m_vulkanDevice);
|
||||
}
|
||||
catch (std::exception const&)
|
||||
{
|
||||
ms_isVulkanEnabled = false;
|
||||
|
||||
SetupOpenGLView(ms_window);
|
||||
}
|
||||
|
||||
if (fb == nullptr)
|
||||
{
|
||||
fb = new OpenGLRenderer::OpenGLFrameBuffer(0, fullscreen);
|
||||
|
|
Loading…
Reference in a new issue