From ed07a9abc67d5bf95e80c8dc8e589413668f802b Mon Sep 17 00:00:00 2001 From: Edward Raleigh Date: Fri, 12 Nov 2021 16:13:22 -0800 Subject: [PATCH] added fix in case CheckPresentDurationSupport fails to set m_minDuration --- Game.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Game.cpp b/Game.cpp index 80f0cfd..73c8e67 100644 --- a/Game.cpp +++ b/Game.cpp @@ -1839,6 +1839,9 @@ void Game::UpdateDxgiRefreshRatesInfo() &closestLargerPresentDuration)); m_minDuration = closestLargerPresentDuration; + if (m_minDuration == 0 && m_displayFrequency != 0) // if CheckPresentDurationSupport fails to set m_minDuration, try to set with m_displayFrequency instead + m_minDuration = (10000000)/m_displayFrequency; + // this may need to be adjusted based on the VESA criteria. TODO if (m_minDuration > 0 && m_maxDuration > 0) // if Durations are supported, {