From d4f09d18d432ab678f0753ca4774d641f8baec9e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Motiejus=20Jak=C5=A1tys?= <motiejus@jakstys.lt>
Date: Thu, 13 Mar 2025 09:04:29 +0000
Subject: [PATCH] frigate: +audio

---
 modules/services/frigate/default.nix | 12 ++++--------
 1 file changed, 4 insertions(+), 8 deletions(-)

diff --git a/modules/services/frigate/default.nix b/modules/services/frigate/default.nix
index 77dcf1d..3560f9c 100644
--- a/modules/services/frigate/default.nix
+++ b/modules/services/frigate/default.nix
@@ -122,16 +122,13 @@ in
             "ffmpeg:rtsp://localhost:8554/vno4-dome-panorama-orig#hardware=vaapi#video=h264#width=1280"
           ];
           "vno4-dome-ptz-orig" = [
-            #"ffmpeg:rtsp://frigate:\${FRIGATE_RTSP_PASSWORD}@192.168.188.10/cam/realmonitor?channel=2&subtype=0#video=copy#audio=copy"
-            "ffmpeg:rtsp://frigate:\${FRIGATE_RTSP_PASSWORD}@192.168.188.10/cam/realmonitor?channel=2&subtype=0#video=copy"
+            "ffmpeg:rtsp://frigate:\${FRIGATE_RTSP_PASSWORD}@192.168.188.10/cam/realmonitor?channel=2&subtype=0#video=copy#audio=copy"
           ];
           "vno4-dome-ptz-high" = [
-            #"ffmpeg:rtsp://localhost:8554/vno4-dome-ptz-orig#hardware=vaapi#video=h264#audio=copy"
-            "ffmpeg:rtsp://localhost:8554/vno4-dome-ptz-orig#hardware=vaapi#video=h264"
+            "ffmpeg:rtsp://localhost:8554/vno4-dome-ptz-orig#hardware=vaapi#video=h264#audio=copy"
           ];
           "vno4-dome-ptz-low" = [
-            #"ffmpeg:rtsp://localhost:8554/vno4-dome-ptz-orig#hardware=vaapi#video=h264#width=1280#audio=copy"
-            "ffmpeg:rtsp://localhost:8554/vno4-dome-ptz-orig#hardware=vaapi#video=h264#width=1280"
+            "ffmpeg:rtsp://localhost:8554/vno4-dome-ptz-orig#hardware=vaapi#video=h264#width=1280#audio=copy"
           ];
         };
       };
@@ -201,14 +198,13 @@ in
             ffmpeg = {
               output_args = {
                 record = "preset-record-generic-audio-copy";
-                #record = "preset-record-generic";
               };
               inputs = [
                 {
                   path = "rtsp://localhost:8554/vno4-dome-ptz-high";
                   roles = [
                     "record"
-                    #"audio"
+                    "audio"
                   ];
                 }
                 {