From 0ce0a59e7163b30ed5f28c7bcff9b9dab25fe071 Mon Sep 17 00:00:00 2001 From: niten Date: Sun, 26 Nov 2023 21:19:49 -0800 Subject: [PATCH] Add hwaccel option --- frigate-container.nix | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/frigate-container.nix b/frigate-container.nix index 90e3aec..31b22cc 100644 --- a/frigate-container.nix +++ b/frigate-container.nix @@ -22,7 +22,7 @@ let password = "{FRIGATE_MQTT_PASSWORD}"; }; logger.default = cfg.log-level; - # ffmpeg.hwaccel_args = [ "preset-intel-vaapi" ]; + ffmpeg.hwaccel_args = optional (cfg.hwaccel != null) cfg.hwaccel; cameras = mapAttrs' (_: camOpts: nameValuePair camOpts.name { ffmpeg.inputs = [ @@ -74,6 +74,12 @@ in { }; }; + hwaccel = mkOption { + type = nullOr str; + description = "Hardware acceleration driver."; + default = null; + }; + retention = { default = mkOption { type = int;