Start your new game dev life with Godot and you immediately notice very bad screen tearing in your first builds? The fix is easy and fast!

 

Liam Dawe is the big hero once again at Gaming on Linux, coming to the rescue with a fast fix (circa 2017) for this long standing issue with NVIDIA GPU drivers and, like every combination of hardware that you just happen to own...

Firstly, make sure your Godot game build is using the V-sync option so the runner will apply that feature if your targeting it in your Godot project settings. You can learn more over on Godot 4 Documentation suggestions and best practice for fixing jitter, stutter and input lag.

V-Sync options in Project Settings for Godot 4

Open up your nvidia-settings either from the command line or via the gui. Select the main configuration, select your main screen, then check mark the two select boxes for both Force Compositional Pipeline and Force Full Compositional Pipeline options. Apply and save, quit. We suggest reopening the panel to make sure the settings are actually saved. That's it, no more (or at least less screen tearing)!

The following actions to save the xorg.conf file can be dangerous to your system and potentially cause an Nvidia boot loop/systemd crash on X11 start. Make a backup before proceeding!

 

Note: unless you Save the X configuration file, the next time you reboot your machine (at least on Ubuntu Mate 24.40 LTS) the pipeline settings will revert back to standard. You'll need to export a copy of the configuration and merge the settings into the existing config found, typically at: /etc/X11/xorg.conf (Wayland for standard Ubuntu with the Gnome desktop will be different).

You may get a permission error when you try to save the xorg.conf file, even when running as a super user. According to this quick fix on the Nvidia website, a change in user permissions will allow your user to save the configuration file. Just use: sudo chmod u+x /usr/share/screen-resolution-extra/nvidia-polkit and the file changes for the pipeline will save correctly.

Are you interested in more Godot and gamedev content? Let us know in the comments below or: contact us! Be sure to checkout our new sister-site: Grip Fast Gameworks as we explore the world of opensource game development!