diff --git a/src/d3d11/d3d11_swapchain.cpp b/src/d3d11/d3d11_swapchain.cpp index 441eee604..5b38d22f9 100644 --- a/src/d3d11/d3d11_swapchain.cpp +++ b/src/d3d11/d3d11_swapchain.cpp @@ -115,6 +115,11 @@ namespace dxvk { } + HANDLE STDMETHODCALLTYPE D3D11SwapChain::GetFrameLatencyEvent() { + return m_frameLatencyEvent; + } + + HRESULT STDMETHODCALLTYPE D3D11SwapChain::ChangeProperties( const DXGI_SWAP_CHAIN_DESC1* pDesc) { diff --git a/src/d3d11/d3d11_swapchain.h b/src/d3d11/d3d11_swapchain.h index fa10e3ff3..55b1c18f4 100644 --- a/src/d3d11/d3d11_swapchain.h +++ b/src/d3d11/d3d11_swapchain.h @@ -58,6 +58,8 @@ namespace dxvk { UINT STDMETHODCALLTYPE GetFrameLatency(); + HANDLE STDMETHODCALLTYPE GetFrameLatencyEvent(); + HRESULT STDMETHODCALLTYPE ChangeProperties( const DXGI_SWAP_CHAIN_DESC1* pDesc); diff --git a/src/dxgi/dxgi_interfaces.h b/src/dxgi/dxgi_interfaces.h index 376b06885..f890f921c 100644 --- a/src/dxgi/dxgi_interfaces.h +++ b/src/dxgi/dxgi_interfaces.h @@ -58,6 +58,8 @@ IDXGIVkSwapChain : public IUnknown { virtual UINT STDMETHODCALLTYPE GetFrameLatency() = 0; + virtual HANDLE STDMETHODCALLTYPE GetFrameLatencyEvent() = 0; + virtual HRESULT STDMETHODCALLTYPE ChangeProperties( const DXGI_SWAP_CHAIN_DESC1* pDesc) = 0; diff --git a/src/dxgi/dxgi_swapchain.cpp b/src/dxgi/dxgi_swapchain.cpp index 5b8d25102..d41027747 100644 --- a/src/dxgi/dxgi_swapchain.cpp +++ b/src/dxgi/dxgi_swapchain.cpp @@ -406,8 +406,10 @@ namespace dxvk { HANDLE STDMETHODCALLTYPE DxgiSwapChain::GetFrameLatencyWaitableObject() { - Logger::err("DxgiSwapChain::GetFrameLatencyWaitableObject: Not implemented"); - return nullptr; + if (!(m_desc.Flags & DXGI_SWAP_CHAIN_FLAG_FRAME_LATENCY_WAITABLE_OBJECT)) + return nullptr; + + return m_presenter->GetFrameLatencyEvent(); }