Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Refresh Rate - When does it have an effect for standalone builds?

Discussion in 'General Graphics' started by dogboydog, Jul 4, 2021.

  1. dogboydog

    dogboydog

    Joined:
    Nov 23, 2012
    Posts:
    53
    Hello,

    Is it the case that setting the preferredRefreshRate will only have an effect on Windows, Mac, and Linux players if the screen mode is exclusive full screen? Or should it work for borderless too?

    Since borderless and windowed are just one window on the screen, is it true that they essentially can't influence the refresh rate because that is more a function of the monitor than the game?

    https://docs.unity3d.com/ScriptReference/Screen.SetResolution.html
     
  2. bgolus

    bgolus

    Joined:
    Dec 7, 2012
    Posts:
    12,238
    The refresh rate needs to be set on the monitor itself. When using borderless fullscreen and windowed display modes the screen resolution and refresh rate are set by the desktop. Even if they’re taking up the full screen, they’re still being displayed “over the desktop”. Exclusive full screen allows the resolution and refresh rate user by the monitor to be set to something else.
     
    dogboydog and CoderCoco like this.
  3. dogboydog

    dogboydog

    Joined:
    Nov 23, 2012
    Posts:
    53
    Thanks. So the only way that the preferredRefreshRate will take effect is in exclusive mode. Thanks for confirming.