Skip to content

Commit 467e12c

Browse files
committed
DRMBackend: Fix VRR capable check
1 parent f554d88 commit 467e12c

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/Backends/DRMBackend.cpp

+5-4
Original file line numberDiff line numberDiff line change
@@ -2630,10 +2630,11 @@ int drm_prepare( struct drm_t *drm, bool async, const struct FrameInfo_t *frameI
26302630
{
26312631
drm_update_color_mgmt(drm);
26322632

2633-
const bool bVRRCapable = drm->pConnector && drm->pConnector->GetProperties().vrr_capable &&
2634-
drm->pCRTC && drm->pCRTC->GetProperties().VRR_ENABLED;
2635-
const bool bVRREnabled = bVRRCapable && frameInfo->allowVRR;
2636-
if ( bVRRCapable )
2633+
const bool bIsVRRCapable = drm->pConnector && drm->pConnector->GetProperties().vrr_capable && !!drm->pConnector->GetProperties().vrr_capable->GetCurrentValue();
2634+
const bool bHasVRREnable = drm->pCRTC && drm->pCRTC->GetProperties().VRR_ENABLED;
2635+
2636+
const bool bVRREnabled = bIsVRRCapable && bHasVRREnable && frameInfo->allowVRR;
2637+
if ( bIsVRRCapable )
26372638
{
26382639
if ( bVRREnabled != !!drm->pCRTC->GetProperties().VRR_ENABLED->GetCurrentValue() )
26392640
drm->needs_modeset = true;

0 commit comments

Comments
 (0)