diff options
| author | Egor Yusov <egor.yusov@gmail.com> | 2018-03-30 16:59:44 +0000 |
|---|---|---|
| committer | Egor Yusov <egor.yusov@gmail.com> | 2018-03-30 16:59:44 +0000 |
| commit | 6e300d8c6a0c2157b8d804cd604dad6079429d8d (patch) | |
| tree | f910f1082a8337f02abf91f949870cb6668a3f13 /Tests/TestApp/src/TestApp.cpp | |
| parent | Fixed issue with Win32 MessageProc() not checking if g_pTheApp is null (diff) | |
| download | DiligentEngine-6e300d8c6a0c2157b8d804cd604dad6079429d8d.tar.gz DiligentEngine-6e300d8c6a0c2157b8d804cd604dad6079429d8d.zip | |
Updated submodules; enabled fullscreen mode
Diffstat (limited to 'Tests/TestApp/src/TestApp.cpp')
| -rw-r--r-- | Tests/TestApp/src/TestApp.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/Tests/TestApp/src/TestApp.cpp b/Tests/TestApp/src/TestApp.cpp index 783a7e4..4994c69 100644 --- a/Tests/TestApp/src/TestApp.cpp +++ b/Tests/TestApp/src/TestApp.cpp @@ -123,7 +123,7 @@ void TestApp::InitializeDiligentEngine( pFactoryD3D11->CreateDeviceAndContextsD3D11(DeviceAttribs, &m_pDevice, ppContexts.data(), NumDeferredCtx); if(NativeWindowHandle != nullptr) - pFactoryD3D11->CreateSwapChainD3D11(m_pDevice, ppContexts[0], SCDesc, NativeWindowHandle, &m_pSwapChain); + pFactoryD3D11->CreateSwapChainD3D11(m_pDevice, ppContexts[0], SCDesc, FullScreenModeDesc{}, NativeWindowHandle, &m_pSwapChain); } break; #endif @@ -158,7 +158,7 @@ void TestApp::InitializeDiligentEngine( pFactoryD3D12->CreateDeviceAndContextsD3D12(EngD3D12Attribs, &m_pDevice, ppContexts.data(), NumDeferredCtx); if (!m_pSwapChain && NativeWindowHandle != nullptr) - pFactoryD3D12->CreateSwapChainD3D12(m_pDevice, ppContexts[0], SCDesc, NativeWindowHandle, &m_pSwapChain); + pFactoryD3D12->CreateSwapChainD3D12(m_pDevice, ppContexts[0], SCDesc, FullScreenModeDesc{}, NativeWindowHandle, &m_pSwapChain); } break; #endif @@ -209,7 +209,8 @@ void TestApp::InitializeDiligentEngine( for(Uint32 m=0; m < DisplayModes.size(); ++m) { const auto &Mode = DisplayModes[m]; - ss << " " << Mode.Width << 'x' << Mode.Height << " " << std::setprecision(2) << Mode.RefreshRate << "Hz\n"; + float RefreshRate = (float)Mode.RefreshRateNumerator / (float)Mode.RefreshRateDenominator; + ss << " " << Mode.Width << 'x' << Mode.Height << " " << std::fixed << std::setprecision(2) << RefreshRate << " Hz\n"; } } auto str = ss.str(); |
