From de803b36703978eaba13dca839081cfa1cef730b Mon Sep 17 00:00:00 2001 From: Philip Rebohle Date: Fri, 4 May 2018 17:37:29 +0200 Subject: [PATCH] [dxgi] Report refresh rate as a multiple of 1000 Hz More closely emulates what Windows dows. --- src/dxgi/dxgi_output.cpp | 2 +- src/dxgi/dxgi_swapchain.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/dxgi/dxgi_output.cpp b/src/dxgi/dxgi_output.cpp index 571145df..c633d6de 100644 --- a/src/dxgi/dxgi_output.cpp +++ b/src/dxgi/dxgi_output.cpp @@ -199,7 +199,7 @@ namespace dxvk { DXGI_MODE_DESC mode; mode.Width = devMode.dmPelsWidth; mode.Height = devMode.dmPelsHeight; - mode.RefreshRate = { devMode.dmDisplayFrequency, 1 }; + mode.RefreshRate = { devMode.dmDisplayFrequency * 1000, 1000 }; mode.Format = EnumFormat; mode.ScanlineOrdering = DXGI_MODE_SCANLINE_ORDER_PROGRESSIVE; mode.Scaling = DXGI_MODE_SCALING_UNSPECIFIED; diff --git a/src/dxgi/dxgi_swapchain.cpp b/src/dxgi/dxgi_swapchain.cpp index ba12bbd3..00793b7d 100644 --- a/src/dxgi/dxgi_swapchain.cpp +++ b/src/dxgi/dxgi_swapchain.cpp @@ -170,7 +170,7 @@ namespace dxvk { *ppTarget = nullptr; if (!m_desc.Windowed) - hr = this->GetContainingOutput(ppTarget); + hr = m_adapter->GetOutputFromMonitor(m_monitor, ppTarget); } return hr;