mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-10 14:51:51 +00:00
- replace vid_enablevulkan with vid_preferbackend - disabled startup window selector for this (will replace when the startup screen changes are done)
This commit is contained in:
parent
2c751d214f
commit
bdc7329d32
3 changed files with 17 additions and 8 deletions
|
@ -108,12 +108,16 @@ CUSTOM_CVAR(Int, vid_rendermode, 4, CVAR_ARCHIVE | CVAR_GLOBALCONFIG | CVAR_NOIN
|
|||
// No further checks needed. All this changes now is which scene drawer the render backend calls.
|
||||
}
|
||||
|
||||
CUSTOM_CVAR(Int, vid_enablevulkan, 0, CVAR_ARCHIVE | CVAR_GLOBALCONFIG | CVAR_NOINITCALL)
|
||||
CUSTOM_CVAR(Int, vid_preferbackend, 0, CVAR_ARCHIVE | CVAR_GLOBALCONFIG | CVAR_NOINITCALL)
|
||||
{
|
||||
// [SP] This may seem pointless - but I don't want to implement live switching just
|
||||
// yet - I'm pretty sure it's going to require a lot of reinits and destructions to
|
||||
// do it right without memory leaks
|
||||
|
||||
// 0 - OpenGL
|
||||
// 1 - Vulkan
|
||||
// 2 - SoftPoly v2
|
||||
|
||||
Printf("Changing the video backend requires a restart for " GAMENAME ".\n");
|
||||
}
|
||||
|
||||
|
|
|
@ -51,7 +51,7 @@
|
|||
#include "i_system.h"
|
||||
#include "swrenderer/r_swrenderer.h"
|
||||
|
||||
EXTERN_CVAR(Int, vid_enablevulkan)
|
||||
EXTERN_CVAR(Int, vid_preferbackend)
|
||||
|
||||
extern HWND Window;
|
||||
|
||||
|
@ -129,11 +129,12 @@ void I_InitGraphics ()
|
|||
// are the active app. Huh?
|
||||
}
|
||||
|
||||
#if 1 // always use poly backend on this branch, for now.
|
||||
Video = new Win32PolyVideo();
|
||||
#else
|
||||
if (vid_preferbackend == 2)
|
||||
{
|
||||
Video = new Win32PolyVideo();
|
||||
}
|
||||
#ifdef HAVE_VULKAN
|
||||
else if (vid_enablevulkan == 1)
|
||||
else if (vid_preferbackend == 1)
|
||||
{
|
||||
// first try Vulkan, if that fails OpenGL
|
||||
try
|
||||
|
@ -151,8 +152,11 @@ void I_InitGraphics ()
|
|||
{
|
||||
Video = new Win32GLVideo();
|
||||
}
|
||||
#endif
|
||||
|
||||
if (Video == NULL)
|
||||
Video = new Win32PolyVideo();
|
||||
|
||||
// we somehow STILL don't have a display!!
|
||||
if (Video == NULL)
|
||||
I_FatalError ("Failed to initialize display");
|
||||
|
||||
|
|
|
@ -119,7 +119,8 @@ EXTERN_CVAR (Bool, queryiwad);
|
|||
EXTERN_CVAR (Bool, disableautoload)
|
||||
EXTERN_CVAR (Bool, autoloadlights)
|
||||
EXTERN_CVAR (Bool, autoloadbrightmaps)
|
||||
EXTERN_CVAR (Int, vid_enablevulkan)
|
||||
//EXTERN_CVAR (Int, vid_enablevulkan) // hack - we're just disabling it for now, this code does nothing
|
||||
uint32_t vid_enablevulkan = 0;
|
||||
|
||||
extern HWND Window, ConWindow, GameTitleWindow;
|
||||
extern HANDLE StdOut;
|
||||
|
|
Loading…
Reference in a new issue