1 min read

ARCH LINUX TIPS

修复 N 卡显示画面撕裂问题 Nvidia Tearing [1]

无论使用哪种 compositor ,画面撕裂可以通过强制 full composition pipeline 解决。
测试此选项是否可用,请运行:

nvidia-settings --assign CurrentMetaMode="nvidia-auto-select +0+0 { ForceFullCompositionPipeline = On }"

如果以上操作有效的话,为了使设置效果永久生效,必须在 Xorg 配置文件中写入相应配置。具体设置应该开启 TripleBuffering 并且 AllowIndirectGLXProtocol 设置为禁用。配置案例如下:

# edit /etc/X11/xorg.conf.d/20-nvidia.conf
Section "Device"
        Identifier "Nvidia Card"
        Driver     "nvidia"
        VendorName "NVIDIA Corporation"
        BoardName  "GeForce GTX 1050 Ti"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "Device0"
    Monitor        "Monitor0"
    Option         "metamodes" "nvidia-auto-select +0+0 {ForceCompositionPipeline=On, ForceFullCompositionPipeline=On}"
    Option         "AllowIndirectGLXProtocol" "off"
    Option         "TripleBuffer" "on"
EndSection

KDE 设置鼠标滚轮自然滚动 Natural Scrolling [2]

编辑文件 /usr/share/X11/xorg.conf.d/40-libinput.conf

Section "InputClass"
        Identifier "libinput pointer catchall"
        MatchIsPointer "on"
        MatchDevicePath "/dev/input/event*"
        Driver "libinput"
        Option "NaturalScrolling" "true" # Add this line
EndSection

  1. https://wiki.archlinux.org/index.php/NVIDIA/Troubleshooting#Avoid_screen_tearing ↩︎

  2. https://wiki.archlinux.org/index.php/Libinput#Common_options ↩︎