[Hardware/Nvidia] Add many useful environmental variables

This commit is contained in:
Antoine Viallon 2022-04-05 09:05:24 +02:00
parent 87b70dcca1
commit 4e28b5380e
Signed by: aviallon
GPG key ID: 186FC35EDEB25716
2 changed files with 10 additions and 0 deletions

View file

@ -34,9 +34,17 @@ in
libvdpau-va-gl
vaapiVdpau
];
hardware.opengl.extraPackages32 = with pkgs.pkgsi686Linux; [
libvdpau-va-gl
vaapiVdpau
];
# See documentation here: https://download.nvidia.com/XFree86/Linux-x86_64/510.60.02/README/openglenvvariables.html
environment.variables = ifEnable cfg.useProprietary {
"__GL_YIELD" = "USLEEP"; # use usleep(0) instead of sched_yield() -> better performance in most cases
"__GL_ALLOW_UNOFFICIAL_PROTOCOL" = "1"; # allow unofficial GLX protocol if also set in Xorg conf
"__GL_VRR_ALLOWED" = "1"; # Try to enable G-SYNC VRR if screen AND app is compatible
};
};
}