From 46745da84627710a863b2aeeb16b5129fcff7597 Mon Sep 17 00:00:00 2001 From: exalexi Date: Fri, 18 Jul 2025 01:00:00 +0200 Subject: [PATCH] module.nix: add losslessDLLFile option --- module.nix | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/module.nix b/module.nix index d91ad93..15dc16b 100644 --- a/module.nix +++ b/module.nix @@ -13,6 +13,15 @@ in description = "The lsfg-vk package to use"; default = lsfg-vk; }; + + losslessDLLFile = lib.mkOption { + type = with lib.types; nullOr str; + default = null; + description = '' + Sets the LSFG_DLL_PATH environment variable. + Required if Lossless Scaling isn't installed in a standard location + ''; + }; }; }; @@ -22,5 +31,7 @@ in # Installs the Vulkan implicit layer system-wide environment.etc."vulkan/implicit_layer.d/VkLayer_LS_frame_generation.json".source = "${cfg.package}/share/vulkan/implicit_layer.d/VkLayer_LS_frame_generation.json"; + + environment.sessionVariables.LSFG_DLL_PATH = lib.mkIf (cfg.losslessDLLFile != null) cfg.losslessDLLFile; }; }