Reworked how renderers are hooked.

Some games doesn't initialise Steam before initalizing their Renderer (even if the doc says to) . So instead of waiting for the game to initialize it, hook to the rendering functions and deduce which implementation should be used.
This commit is contained in:
Nemirtingas 2019-08-16 10:36:44 +02:00
parent 4d3c355fcc
commit 40615d07a7
12 changed files with 497 additions and 190 deletions

View file

@ -38,9 +38,9 @@ private:
decltype(&IDXGISwapChain::ResizeTarget) ResizeTarget;
// Hook functions so we know we use DX11
static decltype(D3D12CreateDevice) MyD3D12CreateDevice;
//static decltype(D3D12CreateDevice) MyD3D12CreateDevice;
decltype(D3D12CreateDevice)* D3D12CreateDevice;
//decltype(D3D12CreateDevice)* D3D12CreateDevice;
public:
static void Create(); // Initialize DX11 Hook.