Closed ebaschiera closed 3 years ago
An additional note: this the log of Frigade when ffmpeg can actually get the stream working.
Fontconfig error: Cannot load default config file
ffprobe -v panic -show_error -show_streams -of json "rtsp://192.168.0.140:7447/5fc2196ee4b006a8bdc4307f_1"
Starting detection process: 19
Attempting to load TPU as usb:0
No EdgeTPU detected. Falling back to CPU.
On connect called
{'streams': [{'index': 0, 'codec_name': 'aac', 'codec_long_name': 'unknown', 'codec_type': 'audio', 'codec_time_base': '1/11025', 'codec_tag_string': '[0][0][0][0]', 'codec_tag': '0x0000', 'sample_fmt': 'fltp', 'sample_rate': '11025', 'channels': 1, 'channel_layout': 'mono', 'bits_per_sample': 0, 'r_frame_rate': '0/0', 'avg_frame_rate': '0/0', 'time_base': '1/11025', 'disposition': {'default': 0, 'dub': 0, 'original': 0, 'comment': 0, 'lyrics': 0, 'karaoke': 0, 'forced': 0, 'hearing_impaired': 0, 'visual_impaired': 0, 'clean_effects': 0, 'attached_pic': 0, 'timed_thumbnails': 0}}, {'index': 1, 'codec_name': 'h264', 'codec_long_name': 'unknown', 'codec_type': 'video', 'codec_time_base': '0/2', 'codec_tag_string': '[0][0][0][0]', 'codec_tag': '0x0000', 'width': 0, 'height': 0, 'coded_width': 0, 'coded_height': 0, 'closed_captions': 0, 'has_b_frames': 0, 'level': -99, 'refs': 1, 'is_avc': 'false', 'nal_length_size': '0', 'r_frame_rate': '90000/1', 'avg_frame_rate': '0/0', 'time_base': '1/90000', 'disposition': {'default': 0, 'dub': 0, 'original': 0, 'comment': 0, 'lyrics': 0, 'karaoke': 0, 'forced': 0, 'hearing_impaired': 0, 'visual_impaired': 0, 'clean_effects': 0, 'attached_pic': 0, 'timed_thumbnails': 0}}]}
Camera capture process started for ingresso: 28
Creating ffmpeg process...
ffmpeg -hide_banner -loglevel info -avoid_negative_ts make_zero -fflags nobuffer -flags low_delay -strict experimental -fflags +genpts+discardcorrupt -rtsp_transport tcp -stimeout 5000000 -use_wallclock_as_timestamps 1 -i rtsp://192.168.0.140:7447/5fc2196ee4b006a8bdc4307f_1 -f segment -segment_time 10 -segment_format mp4 -reset_timestamps 1 -strftime 1 -c copy -an -map 0 /cache/ingresso-%Y%m%d%H%M%S.mp4 -f rawvideo -pix_fmt yuv420p pipe:
Camera process started for ingresso: 30
* Serving Flask app "detect_objects" (lazy loading)
* Environment: development
* Debug mode: off
Input #0, rtsp, from 'rtsp://192.168.0.140:7447/5fc2196ee4b006a8bdc4307f_1':
Metadata:
title : FCECDA8FC971_1
Duration: N/A, start: 1606652420.322086, bitrate: N/A
Stream #0:0: Audio: aac, 11025 Hz, mono, fltp
Stream #0:1: Video: h264, yuvj420p(pc, bt709, progressive), 1024x576 [SAR 189:190 DAR 168:95], 5 fps, 35 tbr, 90k tbn, 10 tbc
[segment @ 0x557b2171a0] Opening '/cache/ingresso-20201129132024.mp4' for writing
Output #0, segment, to '/cache/ingresso-%Y%m%d%H%M%S.mp4':
Metadata:
title : FCECDA8FC971_1
encoder : Lavf58.45.100
Stream #0:0: Video: h264, yuvj420p(pc, bt709, progressive), 1024x576 [SAR 189:190 DAR 168:95], q=2-31, 5 fps, 35 tbr, 10240 tbn, 5 tbc
Stream mapping:
Stream #0:1 -> #0:0 (copy)
Stream #0:1 -> #1:0 (h264 (native) -> rawvideo (native))
Press [q] to stop, [?] for help
frame= 0 fps=0.0 q=-1.0 q=0.0 size=N/A time=00:00:00.00 bitrate=N/A speed= 0x
frame= 0 fps=0.0 q=-1.0 q=0.0 size=N/A time=00:00:00.00 bitrate=N/A speed= 0x
frame= 0 fps=0.0 q=-1.0 q=0.0 size=N/A time=00:00:00.00 bitrate=N/A speed= 0x
[swscaler @ 0x557b2e4130] deprecated pixel format used, make sure you did set range correctly
Output #1, rawvideo, to 'pipe:':
Metadata:
title : FCECDA8FC971_1
encoder : Lavf58.45.100
Stream #1:0: Video: rawvideo (I420 / 0x30323449), yuv420p, 1024x576 [SAR 189:190 DAR 168:95], q=2-31, 35389 kb/s, 5 fps, 5 tbn, 5 tbc
Metadata:
encoder : Lavc58.91.100 rawvideo
Try specifying the width
and height
parameters for your camera in the config. It is failing when trying to autodetect the resolution.
It works! Thanks!
Describe the bug ffmpeg cannot decode the stream coming from my ubiquiti camera unless that stream is already open with another client (for example VLC Player). Is it a matter of ffmpeg timeouts or something like that? Please note that the rtsp ip address is the ubiquiti video controller, not the direct camera url.
Thanks!
Version of frigate Home Assistant Add-on: Frigate NVR 1.3
Config file Include your full config file wrapped in triple back ticks.
Logs
Frigate debug stats
FFprobe from your camera
This is run from another machine, based on Ubuntu 20.04
Screenshots None
Computer Hardware
Camera Info:
Additional context None