diff options
| author | assiduous <assiduous@diligentgraphics.com> | 2020-02-02 23:07:25 +0000 |
|---|---|---|
| committer | assiduous <assiduous@diligentgraphics.com> | 2020-02-02 23:07:25 +0000 |
| commit | 4c73f2d3fd5305b82d3413ebeab74cc566b57f33 (patch) | |
| tree | a74cd97e9015a753b706e7305e3336430b634aa6 /Graphics/GraphicsEngineD3DBase | |
| parent | Cleaned-up NativeWindow PR (diff) | |
| download | DiligentCore-4c73f2d3fd5305b82d3413ebeab74cc566b57f33.tar.gz DiligentCore-4c73f2d3fd5305b82d3413ebeab74cc566b57f33.zip | |
Updated swap chain creation functions to use NativeWindow struct
Diffstat (limited to 'Graphics/GraphicsEngineD3DBase')
| -rw-r--r-- | Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.hpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.hpp b/Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.hpp index b1088b4f..9479d72e 100644 --- a/Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.hpp +++ b/Graphics/GraphicsEngineD3DBase/include/SwapChainD3DBase.hpp @@ -47,11 +47,11 @@ public: IDeviceContext* pDeviceContext, const SwapChainDesc& SCDesc, const FullScreenModeDesc& FSDesc, - void* pNativeWndHandle) : + const NativeWindow& Window) : // clang-format off TBase{pRefCounters, pDevice, pDeviceContext, SCDesc}, m_FSDesc {FSDesc}, - m_pNativeWndHandle {pNativeWndHandle} + m_Window {Window} // clang-format on {} @@ -74,7 +74,7 @@ protected: void CreateDXGISwapChain(IUnknown* pD3D11DeviceOrD3D12CmdQueue) { #if PLATFORM_WIN32 - auto hWnd = reinterpret_cast<HWND>(m_pNativeWndHandle); + auto hWnd = reinterpret_cast<HWND>(m_Window.hWnd); if (m_SwapChainDesc.Width == 0 || m_SwapChainDesc.Height == 0) { RECT rc; @@ -194,7 +194,7 @@ protected: hr = factory->CreateSwapChainForCoreWindow( pD3D11DeviceOrD3D12CmdQueue, - reinterpret_cast<IUnknown*>(m_pNativeWndHandle), + reinterpret_cast<IUnknown*>(m_Window.pWindow), &swapChainDesc, nullptr, &pSwapChain1); @@ -242,7 +242,7 @@ protected: FullScreenModeDesc m_FSDesc; CComPtr<DXGISwapChainType> m_pSwapChain; - void* m_pNativeWndHandle; + NativeWindow m_Window; }; } // namespace Diligent |
