Apply the wiki's fix for screen tearing
- See <https://nixos.wiki/wiki/Nvidia>'s section on how to "Fix screen tearing"
diff --git a/modules/nvidia.nix b/modules/nvidia.nix
index f7aa1bd..8ae9a7f 100644
--- a/modules/nvidia.nix
+++ b/modules/nvidia.nix
@@ -10,7 +10,14 @@
in
{
config = {
- services.xserver.videoDrivers = [ "nvidia" ];
+ services.xserver = {
+ videoDrivers = [ "nvidia" ];
+ screenSection = ''
+ Option "metamodes" "nvidia-auto-select +0+0 {ForceFullCompositionPipeline=On}"
+ Option "AllowIndirectGLXProtocol" "off"
+ Option "TripleBuffer" "on"
+ '';
+ };
hardware = {
opengl.enable = true;
nvidia = {