Returns a bitwise combination of HDRDisplaySupportFlags describing the support for HDR displays on the system.
The flags describe what the current platform and graphics API implement. They don't describe the display that's currently connected. The value doesn't change when you attach or detach an HDR-capable monitor, and it's the same for every display on the system. Each graphics API sets the flags when it initializes, so a system with no HDR-capable monitor can still report HDRDisplaySupportFlags.Supported.
Use this property to decide whether to offer HDR options in an application. To find out whether HDR output is available on a specific display, use HDROutputSettings.available. To find out whether Unity currently renders to HDR, use HDROutputSettings.active.
using UnityEngine;
public class HDRDisplaySupportExample : MonoBehaviour { void Start() { // Reports what the platform and graphics API implement. // It doesn't reflect the display that's currently connected. HDRDisplaySupportFlags flags = SystemInfo.hdrDisplaySupportFlags; Debug.Log($"Platform HDR support: {flags}");
if ((flags & HDRDisplaySupportFlags.Supported) == 0) { Debug.Log("This platform doesn't support HDR output."); return; }
if ((flags & HDRDisplaySupportFlags.RuntimeSwitchable) != 0) Debug.Log("This platform can turn HDR output on and off at runtime.");
// Query the display itself to find out whether HDR is actually available. Debug.Log($"HDR available on the main display: {HDROutputSettings.main.available}"); } }