HLS Stream Questions
I'm using frigate, and I am ingesting an HLS stream from the web. I can launch the container, and go2rtc is ingesting the feed and creating an rtsp feed correctly. I am able to view it flawlessly using ffplay on the host pointed to the rtsp stream. However, i'm experiencing issues with stable feeds of the single and multi camera view, as well as the stream view from the go2rtc web UIs. attached is my current stream definition and camera definitions that i'm using for frigate:
go2rtc:
streams:
people: ffmpeg:https://streamingwebcams.mtu.edu:1935/rtplive/camera026.stream/playlist.m3u8#video=h264#width=1280#height=720
rtsp:
transport: tcp, udp
ffmpeg:
input: '-reconnect 1 -reconnect_at_eof 1 -reconnect_streamed 1 -reconnect_delay_max 4 -fflags +discardcorrupt -avoid_negative_ts make_zero -use_wallclock_as_timestamps 1'
raw: '-buffer_size 10000000 -fflags +genpts -flags low_delay -vf "scale=640:-2" -r 5 -c:v h264_nvenc -preset fast -rc:v vbr -b:v 800k -maxrate 1200k -bufsize 1200k -profile:v high -level:v 4.1'
log:
level: debug
streams: debug
Below, is the parsed go2rtc.yaml that is generated inside the container:
root@fe2345ee8004:/opt/frigate# cat /dev/shm/go2rtc.yaml
streams:
people:
ffmpeg:https://streamingwebcams.mtu.edu:1935/rtplive/camera026.stream/playlist.m3u8#video=h264#width=1280#height=720
rtsp:
transport: tcp, udp
ffmpeg:
input: -reconnect 1 -reconnect_at_eof 1 -reconnect_streamed 1
-reconnect_delay_max 4 -fflags +discardcorrupt -avoid_negative_ts make_zero
-use_wallclock_as_timestamps 1
raw: -buffer_size 10000000 -fflags +genpts -flags low_delay -vf "scale=640:-2"
-r 5 -c:v h264_nvenc -preset fast -rc:v vbr -b:v 800k -maxrate 1200k
-bufsize 1200k -profile:v high -level:v 4.1
log:
level: debug
streams: debug
bin: /usr/lib/ffmpeg/7.0/bin/ffmpeg
api:
origin: '*'
hass:
config: /homeassistant
log:
format: text
webrtc:
candidates:
- stun:8555
It seems that something in my configuration is causing issues for the go2rtc and frigate web UI's connecting to the rtsp outputs to stream the MSE in their respective windows/viewers. Do you have recommendations on what to change, or issues with my configurations?
I have reached out to the frigate team and worked to troubleshoot this on my own. Their inputs are here for reference:
https://github.com/blakeblackshear/frigate/discussions/20877#discussioncomment-15015708