From 5d4908d2e2fcc4067e7432d9d5197930cb7e8cc7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Geoffrey=20=E2=80=9CFrogeye=E2=80=9D=20Preud=27homme?= Date: Sun, 18 Feb 2024 14:12:32 +0100 Subject: [PATCH 1/2] update-local-flakes: Fail early --- hm/rebuild/update-local-flakes.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/hm/rebuild/update-local-flakes.py b/hm/rebuild/update-local-flakes.py index 8833695..51723f4 100755 --- a/hm/rebuild/update-local-flakes.py +++ b/hm/rebuild/update-local-flakes.py @@ -51,7 +51,8 @@ def process_flake(flake: str) -> None: "--update-input", dep_name, ] - subprocess.run(cmd, cwd=dir) + p = subprocess.run(cmd, cwd=dir) + p.check_returncode() if __name__ == "__main__": From ac0724d97a62b94ae82301fe5b9866d0fca00a05 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Geoffrey=20=E2=80=9CFrogeye=E2=80=9D=20Preud=27homme?= Date: Mon, 19 Feb 2024 00:55:45 +0100 Subject: [PATCH 2/2] pindakaas: Fix video stuttering --- hm/desktop/default.nix | 3 +-- pindakaas/hardware.nix | 14 ++++++++++++-- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/hm/desktop/default.nix b/hm/desktop/default.nix index cbdd5e7..95bb15c 100644 --- a/hm/desktop/default.nix +++ b/hm/desktop/default.nix @@ -53,9 +53,8 @@ in audio-display = false; save-position-on-quit = true; osc = false; # Required by thumbnail script - # Hardware acceleration (from https://nixos.wiki/wiki/Accelerated_Video_Playback#MPV) + # Hardware acceleration (from https://nixos.wiki/wiki/Accelerated_Video_Playback#MPV, vo=gpu already default) hwdec = "auto-safe"; - vo = "gpu"; profile = "gpu-hq"; }; scripts = with pkgs.mpvScripts; [ thumbnail ]; diff --git a/pindakaas/hardware.nix b/pindakaas/hardware.nix index 783d473..64b4259 100644 --- a/pindakaas/hardware.nix +++ b/pindakaas/hardware.nix @@ -1,4 +1,4 @@ -{ pkgs, config, ... }: +{ pkgs, lib, config, ... }: { boot = { # nixos-hardware use latest kernel by default. It has been set a while ago, we maybe don't need it anymore? @@ -14,7 +14,7 @@ frogeye.desktop = { x11_screens = [ "DP-1" "eDP-1" ]; - maxVideoHeight = 720; + maxVideoHeight = 1080; phasesBrightness = { enable = true; jour = "3500"; @@ -23,6 +23,16 @@ }; }; + # Hardware decoding as suggested in link, works but doesn't seem to help much + # (at least in dropped frames and perf stat output). + # https://wiki.pine64.org/wiki/Mainline_Hardware_Decoding#mpv + # Might be worth if using CI to build. + + home-manager.sharedModules = [{ + # gpu-hq is too much for it to handle, even with hw decoding + config.programs.mpv.config.profile = lib.mkForce "default"; + }]; + zramSwap = { # Not capable of building itself otherwise enable = true;