Variable refresh rate - ArchWiki

# Variable refresh rate

From ArchWiki
Jump to navigation Jump to search

Related articles

- Xrandr
- Xorg
- AMDGPU
- NVIDIA
- Sway

Variable refresh rate (VRR), also referred to as adaptive sync, allows the monitor to adjust its refresh rate to the output signal. This allows for games to eliminate screen tearing with less of the usual downsides of Vsync (such as stuttering). For a comprehensive look at VRR see PC Gaming Wiki.

## Overview

There are multiple implementations of VRR:

- FreeSync is AMD's implementation of VESA's VRR standard, and the phrases are often used interchangeably. FreeSync branded monitors should be compatible with all VESA compatible drivers.

- Gsync is NVIDIA's proprietary hardware and software implementation of VRR.

- Intel plans on implementing VESA's standard in their upcoming 10th or 11th Gen. [1] [2]

VRR compatibility and implementations

Driver | VESA | Gsync
--- | --- | ---
AMDGPU | FreeSync | No
Intel | Planned | No
Nouveau | Not Supported | Not Supported
NVIDIA | Gsync Compatible | Gsync

Note: Nvidia GPUs older than their 10 series do not support "Gsync Compatible" monitors.

## Configuration

### Enable on AMDGPU

FreeSync is only available if your monitor is compatible with FreeSync, as well as if your GPU is compatible with FreeSync.

If you are using a laptop, you can check if your laptop is compatible with FreeSync.

#### Using an Xorg conf file

Add the line to your .conf file.

    Option "VariableRefresh" "true"

For more information on Xorg configuration see the AMDGPU page.

Verify vrr_capable is set to 1 using xrandr:

    $ xrandr --props

    vrr_capable: 1
            range: (0, 1)

### Enable on NVIDIA

#### Using a Xorg conf file

This article or section needs expansion.

Reason: This section needs info. (Discuss in Talk:Variable refresh rate#)

#### Via nvidia-settings

Gsync monitors should automatically be enabled. To enable Gsync compatible monitors do the following:

- In nvidia-settings go to the "X Server Display Configuration" page, then under the Advanced button is the option to "Allow G-SYNC on monitor not validated as G-SYNC Compatible". Then click apply.
- Now, under OpenGL settings, check "Allow Gsync/Gsync Compatible."

Tip: In the same menu, you can check the "show Gsync indicator" option to display an indicator that Gsync is working in the top right corner.

### Using Sway

Note: No Sway release includes adaptive sync yet, though you can install sway-gitAUR and wlroots-gitAUR as their master branches include support. [3]

To enable it for all of your outputs you can add the following to the sway config, or apply the setting to on a per output basis:

    output * adaptive_sync on

You can verify that your display supports adaptive sync with swaymsg:

    $ swaymsg -t get_outputs

    Output DP-1 'Display Name'
      Adaptive sync: enabled

## Testing

If you are using nvidia GPU, you can test gsync with the Unofficial OpenGL G-SYNC Demo for Linux. Install the gl-gsync-demoAUR package. Launch the demo. You will be able to toggle the vrr and vsync parameters at runtime, so you can observe resulting effects. See project's Readme for more information.

According to this page: "gl-gsync-demo is made with G-SYNC but that doesn't matter, it will test AMD adaptive sync just fine". However, it may still not work as expected for FreeSync testing.

There is a VRRTest tool. It uses OpenGL and can run under Windows and Linux, so you can test it with wine. Currently, wine support is broken, see this. To test natively on linux, install love package, clone repository, then run `$ love /path/to/cloned/repository`.

## Change VRR Range of a FreeSync Monitor

Freesync monitors usually have a limited range for VRR that are much lower than their max refresh rate. It should be possible to overclock the monitor to change the Freesync range.

Warning: Overclocking your monitor may cause it to run hot and possibly cause harm. Proceed at your own risk.

### Editing the EDID File

External Display Identification Data (EDID) stores driver information about your monitor. By default, this file is sent by your monitor and read on connect. You will need to extract this file using something like read-edid or nvidia-settings.

You can edit this file with wxedidAUR

This article or section needs expansion.

Reason: This section needs verification from users with a freesync monitor please consider contributing. (Discuss in Talk:Variable refresh rate#)

You may follow one of the guides of people changing the freesync range on Windows: [4][5]

Process of overclocking on Linux: [6]

Make a Xorg .conf file for your monitor and add a path to the custom EDID file you have edited. See xrandr to find find out the other information about your monitor.

    /etc/X11/xorg.conf.d/10-monitor.conf

    Section "Screen"
        Identifier "Screen0"
        Device "nvidia" # e.g. Radeon, nvidia
        Monitor "DP1"
        Option “CustomEDID” “MONITOR:/home/USER/Desktop/modified-edid.bin”
    EndSection

Note: Edit “MONITOR” in the file to be the correct display ID. You can get the display ID with the `xrandr -–query` command.

## Tips and Tricks

### Remove applications from Blacklist

Mesa has a list of blacklisted applications to avoid unexpected behavior, you can edit this blacklist here:

    /usr/share/drirc.d/00-mesa-defaults.conf

## Limitations

- Wayland is not supported yet [7].
- The monitor must be plugged in via DisplayPort. Some displays which implement (part of) the HDMI 2.1 specification also support VRR over HDMI. This is supported by the Nvidia driver and will likely be supported by the AMD driver in the future.
- Only one monitor may be used at a time with Gsync and possibly Freesync.
- Compositors will most likely need to be disabled before the OpenGl/Vulkan program is started.
- Mesa blacklists many applications including video players.
- Although tearing is much less noticeable at higher refresh rates, FreeSync monitors often have a limited range for their VRR of 90Hz, which can be much lower than their max refresh rate. See Change VRR Range of a FreeSync Monitor.

Categories:

- Graphics
- X server
- Gaming

Hidden category:

- Pages or sections flagged with Template:Expansion