1
1
Fork 0

custom: add vrr option

Signed-off-by: Myned <dev@bjork.tech>
This commit is contained in:
Myned 2024-12-31 12:43:57 -06:00
parent 8dccc6eaff
commit 6d3e618ed5
Signed by: Myned
GPG key ID: C7224454F7881A34
4 changed files with 7 additions and 2 deletions

View file

@ -13,7 +13,8 @@
width = 3440;
height = 1440;
refresh = 100;
desktops.niri.output.connectors = ["DP-1" "HDMI-A-1"];
vrr = true;
desktops.niri.output.connectors = ["DP-1" "DP-2" "DP-3" "HDMI-A-1" "HDMI-A-2" "HDMI-A-3"];
programs.looking-glass = {
enable = true;

View file

@ -24,6 +24,7 @@ in {
width = mkOption {default = 1920;};
height = mkOption {default = 1080;};
refresh = mkOption {default = 60;};
vrr = mkOption {default = false;};
ultrawide = mkOption {default = cfg.width * 9 / 16 > cfg.height;}; # Wider than 16:9
hidpi = mkOption {default = cfg.scale > 1;};
scale = mkOption {default = 1;};

View file

@ -15,6 +15,7 @@ in {
home-manager.sharedModules = [
{
# https://github.com/YaLTeR/niri/wiki/Configuration:-Outputs
#?? niri msg outputs
programs.niri.settings.outputs = listToAttrs (forEach cfg.connectors (connector: {
name = connector;
@ -27,6 +28,7 @@ in {
};
scale = config.custom.scale;
variable-refresh-rate = mkIf config.custom.vrr "on-demand"; #!! Requires window-rule
};
}));
}

View file

@ -96,7 +96,8 @@ in {
# Games
matches = [
{app-id = "^.*\.(exe|x86_64)$";}
{app-id = "^moe\.launcher\..+$";}
{app-id = "^love$";} # vrrtest
{app-id = "^moe\.launcher\..+$";} # Anime Game Launcher
{app-id = "^net\.retrodeck\.retrodeck$";}
{app-id = "^steam_app_.+$";}
];