mirror of
https://github.com/SebastianWendel/nixpkgs.git
synced 2024-09-20 12:29:02 +02:00
nixos/nvidia: add hardware.nvidia.forceFullCompositionPipeline
This commit is contained in:
parent
977df9de2e
commit
446d2cb021
|
@ -163,8 +163,19 @@ in
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
|
hardware.nvidia.forceFullCompositionPipeline = lib.mkOption {
|
||||||
|
default = false;
|
||||||
|
type = types.bool;
|
||||||
|
description = ''
|
||||||
|
Whether to force-enable the full composition pipeline.
|
||||||
|
This sometimes fixes screen tearing issues.
|
||||||
|
This has been reported to reduce the performance of some OpenGL applications and may produce issues in WebGL.
|
||||||
|
It also drastically increases the time the driver needs to clock down after load.
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
hardware.nvidia.package = lib.mkOption {
|
hardware.nvidia.package = lib.mkOption {
|
||||||
type = lib.types.package;
|
type = types.package;
|
||||||
default = config.boot.kernelPackages.nvidiaPackages.stable;
|
default = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||||
defaultText = literalExpression "config.boot.kernelPackages.nvidiaPackages.stable";
|
defaultText = literalExpression "config.boot.kernelPackages.nvidiaPackages.stable";
|
||||||
description = ''
|
description = ''
|
||||||
|
@ -260,8 +271,14 @@ in
|
||||||
screenSection =
|
screenSection =
|
||||||
''
|
''
|
||||||
Option "RandRRotation" "on"
|
Option "RandRRotation" "on"
|
||||||
${optionalString syncCfg.enable "Option \"AllowEmptyInitialConfiguration\""}
|
'' + optionalString syncCfg.enable ''
|
||||||
'';
|
Option "AllowEmptyInitialConfiguration"
|
||||||
|
'' + optionalString cfg.forceFullCompositionPipeline ''
|
||||||
|
Option "metamodes" "nvidia-auto-select +0+0 {ForceFullCompositionPipeline=On}"
|
||||||
|
Option "AllowIndirectGLXProtocol" "off"
|
||||||
|
Option "TripleBuffer" "on"
|
||||||
|
''
|
||||||
|
;
|
||||||
};
|
};
|
||||||
|
|
||||||
services.xserver.serverLayoutSection = optionalString syncCfg.enable ''
|
services.xserver.serverLayoutSection = optionalString syncCfg.enable ''
|
||||||
|
|
Loading…
Reference in a new issue