mirror of https://github.com/AxioDL/boo.git
Better branching logic for Vulkan init
This commit is contained in:
parent
10988fa37e
commit
26b1e25077
|
@ -233,21 +233,19 @@ public:
|
||||||
{
|
{
|
||||||
#if BOO_HAS_VULKAN
|
#if BOO_HAS_VULKAN
|
||||||
/* Check for Vulkan presence and preference */
|
/* Check for Vulkan presence and preference */
|
||||||
bool hasVk = loadVk();
|
bool tryVulkan = true;
|
||||||
if (hasVk)
|
for (const std::string& arg : args)
|
||||||
{
|
{
|
||||||
for (const std::string& arg : args)
|
if (!arg.compare("--gl"))
|
||||||
{
|
{
|
||||||
if (!arg.compare("--gl"))
|
tryVulkan = false;
|
||||||
{
|
break;
|
||||||
dlclose(m_vkHandle);
|
|
||||||
m_vkHandle = nullptr;
|
|
||||||
m_getVkProc = 0;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (tryVulkan)
|
||||||
|
loadVk();
|
||||||
|
|
||||||
if (m_getVkProc)
|
if (m_getVkProc)
|
||||||
Log.report(logvisor::Info, "using Vulkan renderer");
|
Log.report(logvisor::Info, "using Vulkan renderer");
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue