From 62816a6b2a2571b237907fa72371fcb58457e4e4 Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Mon, 24 Nov 2025 00:06:40 -0600 Subject: [PATCH] Prioritize AV1 over H.264 if HEVC is unavailable on Windows Some Windows PCs are shipping with HEVC disabled in firmware, even though they support AV1. --- app/streaming/session.cpp | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/app/streaming/session.cpp b/app/streaming/session.cpp index 3742ae25..c3b5a312 100644 --- a/app/streaming/session.cpp +++ b/app/streaming/session.cpp @@ -818,10 +818,25 @@ bool Session::initialize(QQuickWindow* qtWindow) } } #else - // Deprioritize AV1 unless we can't hardware decode HEVC and have HDR enabled. + // Deprioritize AV1 unless we can't hardware decode HEVC, and have HDR enabled + // or we're on Windows. + // + // Normally, we'd assume hardware that can't decode HEVC definitely can't decode + // AV1 either, and we wouldn't even bother probing for AV1 support. However, some + // Windows business systems have HEVC support disabled in firmware from the factory, + // yet they can still decode AV1 in hardware. To avoid falling back to H.264 on + // these systems, we don't deprioritize AV1. This firmware-based HEVC licensing + // behavior seems to be unique to Windows, and Linux on the same system is able + // to decode HEVC in hardware normally using VAAPI. + // https://www.reddit.com/r/GeForceNOW/comments/1omsckt/psa_be_wary_of_purchasing_dell_computers_with/ + // // We want to keep AV1 at the top of the list for HDR with software decoding // because dav1d is higher performance than FFmpeg's HEVC software decoder. - if (hevcDA == DecoderAvailability::Hardware || !m_Preferences->enableHdr) { + if (hevcDA == DecoderAvailability::Hardware +#ifndef Q_OS_WIN32 + || !m_Preferences->enableHdr +#endif + ) { m_SupportedVideoFormats.deprioritizeByMask(VIDEO_FORMAT_MASK_AV1); } #endif