Size: a a a

ioBroker smarthome

2021 April 15

LS

Lex Smooth in ioBroker smarthome
На камере?
источник

AF

Alex F. in ioBroker smarthome
в ffmpeg url
источник

LS

Lex Smooth in ioBroker smarthome
ffmpeg -y -i rtsp://admin:qeqweqwe@192.168.55.25:554/live -t 5 -f mp4 -vcodec copy -pix_fmt yuv420p -an -vf scale=w=704:h=576:force_original_aspect_ratio=decrease -r 25 /opt/iobroker/out2.mp4
источник

AF

Alex F. in ioBroker smarthome
ну так -vcodec copy убери
источник

AA

Andrey Anopov in ioBroker smarthome
а scale зачем?
источник

AF

Alex F. in ioBroker smarthome
иначе он не может скалировать
источник

AF

Alex F. in ioBroker smarthome
картинку уменьшить
источник

AA

Andrey Anopov in ioBroker smarthome
зачем?
источник

AF

Alex F. in ioBroker smarthome
понизить время отработки создания файла
источник

AF

Alex F. in ioBroker smarthome
ну и конечный файл будет меньше в два-три раза
источник

AA

Andrey Anopov in ioBroker smarthome
мля. при "-vcodec copy" будет минимальное время. Размер файла очень важен?
источник

LS

Lex Smooth in ioBroker smarthome
pi@raspberrypi:~ $ ffmpeg -y -i rtsp://admin:qweqweqwe@192.168.55.25:554/live -t 5 -f mp4 -vcodec libx264 -pix_fmt yuv420p -an -vf scale=w=704:h=576:force_original_aspect_ratio=decrease -r 25 /opt/iobroker/out2.mp4
ffmpeg version 3.2.15-0+deb9u2 Copyright (c) 2000-2020 the FFmpeg developers
 built with gcc 6.3.0 (Raspbian 6.3.0-18+rpi1+deb9u1) 20170516
 configuration: --prefix=/usr --extra-version=0+deb9u2 --toolchain=hardened --libdir=/usr/lib/arm-linux-gnueabihf --incdir=/usr/include/arm-linux-gnueabihf --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libebur128 --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libopencv --enable-libx264 --enable-shared
 libavutil      55. 34.101 / 55. 34.101
 libavcodec     57. 64.101 / 57. 64.101
 libavformat    57. 56.101 / 57. 56.101
 libavdevice    57.  1.100 / 57.  1.100
 libavfilter     6. 65.100 /  6. 65.100
 libavresample   3.  1.  0 /  3.  1.  0
 libswscale      4.  2.100 /  4.  2.100
 libswresample   2.  3.100 /  2.  3.100
 libpostproc    54.  1.100 / 54.  1.100
[rtsp @ 0x158b5f0] max delay reached. need to consume packet
[rtsp @ 0x158b5f0] RTP: missed 37 packets
[h264 @ 0x158e400] error while decoding MB 2 36, bytestream -11
[h264 @ 0x158e400] concealing 3887 DC, 3887 AC, 3887 MV errors in P frame
Input #0, rtsp, from 'rtsp://admin:
qweqweqwe@192.168.55.25:554/live':
 Metadata:
   title           : Media Server
 Duration: N/A, start: 0.280000, bitrate: N/A
   Stream #0:0: Video: h264 (Main), yuvj420p(pc, bt709, progressive), 1920x1080 [SAR 1:1 DAR 16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc
[swscaler @ 0x15bb150] deprecated pixel format used, make sure you did set range correctly
[libx264 @ 0x15cac90] using SAR=1/1
[libx264 @ 0x15cac90] using cpu capabilities: ARMv6 NEON
[libx264 @ 0x15cac90] profile High, level 3.0
[libx264 @ 0x15cac90] 264 - core 148 r2748 97eaef2 - H.264/MPEG-4 AVC codec - Copyleft 2003-2016 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=6 lookahead_threads=1 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=25 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=crf mbtree=1 crf=23.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
Output #0, mp4, to '/opt/iobroker/out2.mp4':
 Metadata:
   title           : Media Server
   encoder         : Lavf57.56.101
   Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 704x396 [SAR 1:1 DAR 16:9], q=-1--1, 25 fps, 12800 tbn, 25 tbc
   Metadata:
     encoder         : Lavc57.64.101 libx264
   Side data:
     cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
Stream mapping:
 Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
Press [q] to stop, [?] for help
[h264 @ 0x16102f0] error while decoding MB 2 36, bytestream -11
[h264 @ 0x16102f0] concealing 3887 DC, 3887 AC, 3887 MV errors in P frame
frame=    2 fps=0.0 q=0.0 size=       0kB time=00:00:00.00 bitrate=N/A dup=0 droPast duration 0.999992 too large
   Last message repeated 6 times
источник

LS

Lex Smooth in ioBroker smarthome
frame=    9 fps=8.5 q=0.0 size=       0kB time=00:00:00.00 bitrate=N/A dup=0 droPast duration 0.999992 too large
   Last message repeated 9 times
frame=   19 fps= 12 q=0.0 size=       0kB time=00:00:00.00 bitrate=N/A dup=0 droPast duration 0.999992 too large
   Last message repeated 9 times
frame=   29 fps= 14 q=0.0 size=       0kB time=00:00:00.00 bitrate=N/A dup=0 droPast duration 0.999992 too large
[rtsp @ 0x158b5f0] max delay reached. need to consume packet
[rtsp @ 0x158b5f0] RTP: missed 357 packets
[rtsp @ 0x158b5f0] max delay reached. need to consume packet
[rtsp @ 0x158b5f0] RTP: missed 60 packets
Past duration 0.999992 too large
[rtsp @ 0x158b5f0] max delay reached. need to consume packet
[rtsp @ 0x158b5f0] RTP: missed 1 packets
Past duration 0.999992 too large
   Last message repeated 2 times
frame=   84 fps= 23 q=28.0 size=     155kB time=00:00:01.24 bitrate=1024.9kbits/[rtsp @ 0x158b5f0] max delay reached. need to consume packet
[rtsp @ 0x158b5f0] RTP: missed 288 packets
[h264 @ 0x16102f0] error while decoding MB 109 5, bytestream -24
[h264 @ 0x16102f0] concealing 7500 DC, 7500 AC, 7500 MV errors in I frame
[rtsp @ 0x158b5f0] max delay reached. need to consume packet
[rtsp @ 0x158b5f0] RTP: missed 42 packets
frame=   91 fps= 21 q=28.0 size=     156kB time=00:00:01.52 bitrate= 839.8kbits/frame=  120 fps= 25 q=28.0 size=     158kB time=00:00:02.68 bitrate= 481.6kbits/frame=  120 fps= 22 q=28.0 size=     158kB time=00:00:02.68 bitrate= 481.6kbits/frame=  120 fps= 19 q=-1.0 Lsize=     188kB time=00:00:04.68 bitrate= 329.1kbits/s dup=73 drop=5 speed=0.739x    
video:186kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 1.160567%
[libx264 @ 0x15cac90] frame I:1     Avg QP:20.59  size: 92174
[libx264 @ 0x15cac90] frame P:43    Avg QP:20.81  size:  2190
[libx264 @ 0x15cac90] frame B:76    Avg QP:32.35  size:    43
[libx264 @ 0x15cac90] consecutive B-frames: 13.3%  3.3% 10.0% 73.3%
[libx264 @ 0x15cac90] mb I  I16..4:  3.3% 18.5% 78.2%
[libx264 @ 0x15cac90] mb P  I16..4:  0.0%  0.0%  0.0%  P16..4: 15.5%  0.8%  1.5%  0.0%  0.0%    skip:82.2%
[libx264 @ 0x15cac90] mb B  I16..4:  0.0%  0.0%  0.0%  B16..8:  2.4%  0.1%  0.0%  direct: 0.0%  skip:97.5%  L0:26.9% L1:71.7% BI: 1.5%
[libx264 @ 0x15cac90] 8x8 transform intra:18.5% inter:39.8%
[libx264 @ 0x15cac90] coded y,uvDC,uvAC intra: 99.2% 90.5% 73.2% inter: 2.8% 2.1% 0.1%
[libx264 @ 0x15cac90] i16 v,h,dc,p: 17% 11% 19% 53%
[libx264 @ 0x15cac90] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 20% 12% 19%  6%  5%  8%  7%  9% 13%
[libx264 @ 0x15cac90] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 20% 12% 14%  8%  8% 10%  8%  8% 11%
[libx264 @ 0x15cac90] i8c dc,h,v,p: 54% 17% 22%  6%
[libx264 @ 0x15cac90] Weighted P-Frames: Y:0.0% UV:0.0%
[libx264 @ 0x15cac90] ref P L0: 91.3%  0.9%  7.0%  0.8%
[libx264 @ 0x15cac90] ref B L0: 97.4%  2.6%
[libx264 @ 0x15cac90] ref B L1: 94.8%  5.2%
[libx264 @ 0x15cac90] kb/s:316.08
источник

AF

Alex F. in ioBroker smarthome
чем больше файл тем больше задержки
источник

LS

Lex Smooth in ioBroker smarthome
переодически лезут ошибки
источник

LS

Lex Smooth in ioBroker smarthome
[h264 @ 0x16102f0] error while decoding MB 109 5, bytestream -24

[h264 @ 0x16102f0] error while decoding MB 2 36, bytestream -11
источник

AF

Alex F. in ioBroker smarthome
ты размер не скалировал на704 x 576
источник

AF

Alex F. in ioBroker smarthome
:)
источник

AA

Andrey Anopov in ioBroker smarthome
при кодировании h264 проц грузится на 100% - это бОльшее зло чем размер файла, если макс. скорость записи носителя во много раз больше скорости видеопотока
источник

AF

Alex F. in ioBroker smarthome
хотя да, есть
источник