Skip to content

Instantly share code, notes, and snippets.

@dmp1ce
Created January 11, 2017 01:35
Show Gist options
  • Save dmp1ce/82debdbdba40776f64c4e33ab759843b to your computer and use it in GitHub Desktop.
Save dmp1ce/82debdbdba40776f64c4e33ab759843b to your computer and use it in GitHub Desktop.
Force vsync on Linux
#!/bin/sh
# https://www.gamingonlinux.com/articles/i-have-finally-found-a-way-to-sort-out-screen-tearing-on-nvidia-with-linux.7213/page=7#comments
sh -c "nvidia-settings --assign CurrentMetaMode=\"$(nvidia-settings -t -q CurrentMetaMode |tr -d "\n"|sed 's/ViewPortIn=/ForceFullCompositionPipeline=On, ViewPortIn=/g'|sed 's/.*:://'|sed 's/^ *//;s/ *$//')\""
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment