Renammed hook_<renderer> to start_hook
parent
2fe5e90294
commit
4d3c355fcc
|
@ -12,7 +12,7 @@
|
||||||
// This is created by DX10_Hook::Create, and deleted by the Hook_Manager if not used
|
// This is created by DX10_Hook::Create, and deleted by the Hook_Manager if not used
|
||||||
static DX10_Hook* hook;
|
static DX10_Hook* hook;
|
||||||
|
|
||||||
void DX10_Hook::hook_dx10(UINT SDKVersion)
|
void DX10_Hook::start_hook()
|
||||||
{
|
{
|
||||||
if (!_hooked)
|
if (!_hooked)
|
||||||
{
|
{
|
||||||
|
@ -34,7 +34,7 @@ void DX10_Hook::hook_dx10(UINT SDKVersion)
|
||||||
SwapChainDesc.SampleDesc.Quality = 0;
|
SwapChainDesc.SampleDesc.Quality = 0;
|
||||||
SwapChainDesc.Windowed = TRUE;
|
SwapChainDesc.Windowed = TRUE;
|
||||||
|
|
||||||
D3D10CreateDeviceAndSwapChain(NULL, D3D10_DRIVER_TYPE_HARDWARE, NULL, 0, SDKVersion, &SwapChainDesc, &pSwapChain, &pDevice);
|
D3D10CreateDeviceAndSwapChain(NULL, D3D10_DRIVER_TYPE_HARDWARE, NULL, 0, D3D10_SDK_VERSION, &SwapChainDesc, &pSwapChain, &pDevice);
|
||||||
|
|
||||||
if (pDevice != nullptr && pSwapChain != nullptr)
|
if (pDevice != nullptr && pSwapChain != nullptr)
|
||||||
{
|
{
|
||||||
|
|
|
@ -22,7 +22,7 @@ private:
|
||||||
DX10_Hook();
|
DX10_Hook();
|
||||||
virtual ~DX10_Hook();
|
virtual ~DX10_Hook();
|
||||||
|
|
||||||
void hook_dx10(UINT SDKVersion);
|
void start_hook();
|
||||||
void resetRenderState();
|
void resetRenderState();
|
||||||
void prepareForOverlay(IDXGISwapChain *pSwapChain);
|
void prepareForOverlay(IDXGISwapChain *pSwapChain);
|
||||||
|
|
||||||
|
|
|
@ -22,7 +22,7 @@ HRESULT GetDeviceAndCtxFromSwapchain(IDXGISwapChain* pSwapChain, ID3D11Device**
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
void DX11_Hook::hook_dx11(UINT SDKVersion)
|
void DX11_Hook::start_hook()
|
||||||
{
|
{
|
||||||
if (!_hooked)
|
if (!_hooked)
|
||||||
{
|
{
|
||||||
|
@ -44,7 +44,7 @@ void DX11_Hook::hook_dx11(UINT SDKVersion)
|
||||||
SwapChainDesc.SampleDesc.Quality = 0;
|
SwapChainDesc.SampleDesc.Quality = 0;
|
||||||
SwapChainDesc.Windowed = TRUE;
|
SwapChainDesc.Windowed = TRUE;
|
||||||
|
|
||||||
D3D11CreateDeviceAndSwapChain(NULL, D3D_DRIVER_TYPE_HARDWARE, NULL, 0, NULL, NULL, SDKVersion, &SwapChainDesc, &pSwapChain, &pDevice, NULL, NULL);
|
D3D11CreateDeviceAndSwapChain(NULL, D3D_DRIVER_TYPE_HARDWARE, NULL, 0, NULL, NULL, D3D11_SDK_VERSION, &SwapChainDesc, &pSwapChain, &pDevice, NULL, NULL);
|
||||||
|
|
||||||
if (pDevice != nullptr && pSwapChain != nullptr)
|
if (pDevice != nullptr && pSwapChain != nullptr)
|
||||||
{
|
{
|
||||||
|
|
|
@ -22,7 +22,7 @@ private:
|
||||||
DX11_Hook();
|
DX11_Hook();
|
||||||
virtual ~DX11_Hook();
|
virtual ~DX11_Hook();
|
||||||
|
|
||||||
void hook_dx11(UINT SDKVersion);
|
void start_hook();
|
||||||
void resetRenderState();
|
void resetRenderState();
|
||||||
void prepareForOverlay(IDXGISwapChain* pSwapChain);
|
void prepareForOverlay(IDXGISwapChain* pSwapChain);
|
||||||
|
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
// This is created by DX12_Hook::Create, and deleted by the Hook_Manager if not used
|
// This is created by DX12_Hook::Create, and deleted by the Hook_Manager if not used
|
||||||
static DX12_Hook* hook;
|
static DX12_Hook* hook;
|
||||||
|
|
||||||
void DX12_Hook::hook_dx12(D3D_FEATURE_LEVEL MinimumFeatureLevel)
|
void DX12_Hook::start_hook()
|
||||||
{
|
{
|
||||||
if (!_hooked)
|
if (!_hooked)
|
||||||
{
|
{
|
||||||
|
|
|
@ -24,7 +24,7 @@ private:
|
||||||
DX12_Hook();
|
DX12_Hook();
|
||||||
virtual ~DX12_Hook();
|
virtual ~DX12_Hook();
|
||||||
|
|
||||||
void hook_dx12(D3D_FEATURE_LEVEL MinimumFeatureLevel);
|
void start_hook();
|
||||||
void resetRenderState();
|
void resetRenderState();
|
||||||
void prepareForOverlay(IDXGISwapChain* pSwapChain);
|
void prepareForOverlay(IDXGISwapChain* pSwapChain);
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,7 @@ static DX9_Hook* hook;
|
||||||
///////// /////////
|
///////// /////////
|
||||||
//////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
void DX9_Hook::hook_dx9(UINT SDKVersion)
|
void DX9_Hook::start_hook()
|
||||||
{
|
{
|
||||||
if (!_hooked)
|
if (!_hooked)
|
||||||
{
|
{
|
||||||
|
@ -28,7 +28,7 @@ void DX9_Hook::hook_dx9(UINT SDKVersion)
|
||||||
IDirect3D9Ex* pD3D;
|
IDirect3D9Ex* pD3D;
|
||||||
IDirect3DDevice9Ex* pDeviceEx;
|
IDirect3DDevice9Ex* pDeviceEx;
|
||||||
|
|
||||||
Direct3DCreate9Ex(SDKVersion, &pD3D);
|
Direct3DCreate9Ex(D3D_SDK_VERSION, &pD3D);
|
||||||
|
|
||||||
D3DPRESENT_PARAMETERS params = {};
|
D3DPRESENT_PARAMETERS params = {};
|
||||||
params.BackBufferWidth = 1;
|
params.BackBufferWidth = 1;
|
||||||
|
|
|
@ -21,7 +21,7 @@ private:
|
||||||
DX9_Hook();
|
DX9_Hook();
|
||||||
virtual ~DX9_Hook();
|
virtual ~DX9_Hook();
|
||||||
|
|
||||||
void hook_dx9(UINT SDKVersion);
|
void start_hook();
|
||||||
void resetRenderState();
|
void resetRenderState();
|
||||||
void prepareForOverlay(IDirect3DDevice9* pDevice);
|
void prepareForOverlay(IDirect3DDevice9* pDevice);
|
||||||
|
|
||||||
|
|
|
@ -16,7 +16,7 @@
|
||||||
// This is created by OpenGL_Hook::Create, and deleted by the Hook_Manager if not used
|
// This is created by OpenGL_Hook::Create, and deleted by the Hook_Manager if not used
|
||||||
static OpenGL_Hook* hook;
|
static OpenGL_Hook* hook;
|
||||||
|
|
||||||
void OpenGL_Hook::hook_ogl()
|
void OpenGL_Hook::start_hook()
|
||||||
{
|
{
|
||||||
if (!_hooked)
|
if (!_hooked)
|
||||||
{
|
{
|
||||||
|
|
|
@ -20,7 +20,7 @@ private:
|
||||||
OpenGL_Hook();
|
OpenGL_Hook();
|
||||||
virtual ~OpenGL_Hook();
|
virtual ~OpenGL_Hook();
|
||||||
|
|
||||||
void hook_ogl();
|
void start_hook();
|
||||||
void resetRenderState();
|
void resetRenderState();
|
||||||
void prepareForOverlay(HDC hDC);
|
void prepareForOverlay(HDC hDC);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue