From 4883506fcf8978d16e26117e5fc8cd1185a313d1 Mon Sep 17 00:00:00 2001 From: Alfonso Gamboa Date: Wed, 12 Jul 2023 13:16:29 -0700 Subject: [PATCH] go2rtc: set opus as default codec --- README.md | 1 + SD_ROOT/wz_mini/etc/go2rtc.yml | 10 ++++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 2f2d09d..8cc0f22 100644 --- a/README.md +++ b/README.md @@ -612,6 +612,7 @@ Feature supported on: ## Latest Updates +* 07-12-23: Fixed RTSP urls for v2 camera's in web config, set config modification in web server to read-only, set lib-opus as default in go2rtc config * 07-11-23: Support 30fps. Add new go2rtc server support for rtsp/hls/webrtc/etc. go2rtc fixed audio in tinycam app. Make video parameters, bitrate, rcmode, and fps independent of rtsp server settings. fixed various init scripts. Recommend to start from a fresh install. * 06-28-23: Add basic auth to web server portal, clarify v2/panv1 setup instructions, http/1.1 RFC7230 compliance * 09-27-22: Add self_hosted iCamera patch by @kohrar, fix config backup script, add ntp client on boot. diff --git a/SD_ROOT/wz_mini/etc/go2rtc.yml b/SD_ROOT/wz_mini/etc/go2rtc.yml index d374df3..cfe31a6 100644 --- a/SD_ROOT/wz_mini/etc/go2rtc.yml +++ b/SD_ROOT/wz_mini/etc/go2rtc.yml @@ -11,10 +11,12 @@ ffmpeg: streams: 1080p: - exec:ffmpeg -fflags +genpts+flush_packets+nobuffer+bitexact -flags +low_delay -thread_queue_size 100 -analyzeduration 50 -probesize 50 -pix_fmt yuv420p -r 30 -i /dev/video1 -flags +global_header -movflags +empty_moov+default_base_moof+frag_keyframe -framerate 30 -video_size 1920x1080 -pix_fmt yuv420p -c:v copy -copyts -rtsp_transport tcp -f rtsp {output} - - exec:ffmpeg -hide_banner -f alsa -ac 1 -i hw:0,0 -c:a libopus -filter:a volume=5 -movflags +empty_moov+default_base_moof+frag_keyframe -muxdelay 0 -muxpreload 0 -ac:a 1 -c:v copy -f rtsp {output} - - exec:ffmpeg -hide_banner -f alsa -ac 1 -i hw:0,0 -c:a aac -filter:a volume=5 -movflags +empty_moov+default_base_moof+frag_keyframe -muxdelay 0 -muxpreload 0 -ac:a 1 -c:v copy -f rtsp {output} + - exec:ffmpeg -hide_banner -f alsa -ac 1 -i hw:0,0 -c:a libopus -filter:a volume=5 -movflags +empty_moov+default_base_moof+frag_keyframe -muxdelay 0 -muxpreload 0 -ac:a 1 -f rtsp {output} +#Uncomment to enable AAC audio +# - exec:ffmpeg -hide_banner -f alsa -ac 1 -i hw:0,0 -c:a aac -filter:a volume=5 -movflags +empty_moov+default_base_moof+frag_keyframe -muxdelay 0 -muxpreload 0 -ac:a 1 -f rtsp {output} 360p: - exec:ffmpeg -fflags +genpts+flush_packets+nobuffer+bitexact -flags +low_delay -thread_queue_size 100 -analyzeduration 50 -probesize 50 -pix_fmt yuv420p -r 30 -i /dev/video2 -framerate 30 -video_size 640x360 -pix_fmt yuv420p -c:v copy -copyts -rtsp_transport tcp -f rtsp {output} - - exec:ffmpeg -hide_banner -f alsa -ac 1 -i hw:2,0 -c:a libopus -filter:a volume=5 -movflags +empty_moov+default_base_moof+frag_keyframe -muxdelay 0 -muxpreload 0 -ac:a 1 -c:v copy -f rtsp {output} - - exec:ffmpeg -hide_banner -f alsa -ac 1 -i hw:2,0 -c:a aac -filter:a volume=5 -movflags +empty_moov+default_base_moof+frag_keyframe -muxdelay 0 -muxpreload 0 -ac:a 1 -c:v copy -f rtsp {output} + - exec:ffmpeg -hide_banner -f alsa -ac 1 -i hw:2,0 -c:a libopus -filter:a volume=5 -movflags +empty_moov+default_base_moof+frag_keyframe -muxdelay 0 -muxpreload 0 -ac:a 1 -f rtsp {output} +#Uncomment to enable AAC audio +# - exec:ffmpeg -hide_banner -f alsa -ac 1 -i hw:2,0 -c:a aac -filter:a volume=5 -movflags +empty_moov+default_base_moof+frag_keyframe -muxdelay 0 -muxpreload 0 -ac:a 1 -f rtsp {output}