Fix incorrect error message when only HEVC decode is available but HEVC encode is not

This commit is contained in:
Cameron Gutman
2022-01-06 22:08:43 -06:00
parent b2265080fd
commit 77d07c7c4d
+2 -2
View File
@@ -653,10 +653,11 @@ bool Session::validateLaunch(SDL_Window* testWindow)
} }
} }
if (hevcForced) {
if (m_Computer->maxLumaPixelsHEVC == 0) { if (m_Computer->maxLumaPixelsHEVC == 0) {
if (hevcForced) {
emitLaunchWarning(tr("Your host PC GPU doesn't support HEVC. " emitLaunchWarning(tr("Your host PC GPU doesn't support HEVC. "
"A GeForce GTX 900-series (Maxwell) or later GPU is required for HEVC streaming.")); "A GeForce GTX 900-series (Maxwell) or later GPU is required for HEVC streaming."));
}
// Moonlight-common-c will handle this case already, but we want // Moonlight-common-c will handle this case already, but we want
// to set this explicitly here so we can do our hardware acceleration // to set this explicitly here so we can do our hardware acceleration
@@ -664,7 +665,6 @@ bool Session::validateLaunch(SDL_Window* testWindow)
m_StreamConfig.supportsHevc = false; m_StreamConfig.supportsHevc = false;
} }
} }
}
if (m_StreamConfig.enableHdr) { if (m_StreamConfig.enableHdr) {
// Turn HDR back off unless all criteria are met. // Turn HDR back off unless all criteria are met.