Add many new preferences to settings DB. Default HEVC to off due to reference frame invalidation not working

This commit is contained in:
Cameron Gutman
2018-06-02 17:07:38 -07:00
parent 2f0e219726
commit bfc0b89926
10 changed files with 40 additions and 20 deletions

View File

@@ -431,12 +431,12 @@ static NSMutableSet* hostList;
_streamConfig.bitRate = [streamSettings.bitrate intValue];
_streamConfig.height = [streamSettings.height intValue];
_streamConfig.width = [streamSettings.width intValue];
_streamConfig.streamingRemotely = [streamSettings.streamingRemotely intValue];
_streamConfig.optimizeGameSettings = YES;
_streamConfig.playAudioOnPC = NO;
_streamConfig.streamingRemotely = streamSettings.streamingRemotely;
_streamConfig.optimizeGameSettings = streamSettings.optimizeGames;
_streamConfig.playAudioOnPC = streamSettings.playAudioOnPC;
// multiController must be set before calling getConnectedGamepadMask
_streamConfig.multiController = YES;
_streamConfig.multiController = streamSettings.multiController;
_streamConfig.gamepadMask = [ControllerSupport getConnectedGamepadMask:_streamConfig];
// TODO: Detect attached surround sound system then address 5.1 TODOs
@@ -447,15 +447,15 @@ static NSMutableSet* hostList;
// HDR requires HDR10 game, HDR10 display, and HEVC Main10 decoder on the client.
// It additionally requires an HEVC Main10 encoder on the server (GTX 1000+).
//
// It should also be a user preference when supported, since some games may require
// higher peak brightness than the iOS device can support to look correct in HDR mode.
// It should also be a user preference, since some games may require higher peak
// brightness than the iOS device can support to look correct in HDR mode.
if (@available(iOS 11.3, *)) {
_streamConfig.enableHdr =
app.hdrSupported && // App supported
(app.host.serverCodecModeSupport & 0x200) != 0 && // HEVC Main10 encoding on host PC GPU
VTIsHardwareDecodeSupported(kCMVideoCodecType_HEVC) && // Decoder supported
(AVPlayer.availableHDRModes & AVPlayerHDRModeHDR10) != 0 && // Display supported
NO; // TODO: User wants it enabled
streamSettings.enableHdr; // User wants it enabled
}
}