<p>This is a follow-up from my previous question <a href="https://video.stackexchange.com/questions/27498/">here</a>. Basically, I'm trying to use <code>FFmpeg</code>'s loop filter to freeze some frames and insert black frames. It's very weird; I swear it was working a few days ago, but now only the blackframe insertion works, the freezing frames doesn't work. So just no frozen frames inside. I don't know what's going wrong?!</p>

<p>Here is my command. I also updated my ffmpeg to the latest version just now:</p>

<pre><code>fn="sample.mp4"

#
ffmpeg -y -i "${fn}" -ss 00:00:05 -to 00:00:06 -r 1/1 _05.png
ffmpeg -y -i "${fn}" -ss 00:00:10 -to 00:00:11 -r 1/1 _10.png
ffmpeg -y -i "${fn}" -ss 00:00:15 -to 00:00:16 -r 1/1 _15.png
ffmpeg -y -i "${fn}" -ss 00:00:20 -to 00:00:21 -r 1/1 _20.png
ffmpeg -y -i "${fn}" -ss 00:00:25 -to 00:00:26 -r 1/1 _25.png
ffmpeg -y -i "${fn}" -ss 00:00:30 -to 00:00:31 -r 1/1 _30.png
ffmpeg -y -i "${fn}" -ss 00:00:35 -to 00:00:36 -r 1/1 _35.png

#
ffmpeg -y -i "${fn}" \
-i _05.png \
-i _10.png \
-i _15.png \
-i _20.png \
-i _25.png \
-i _30.png \
-i _35.png \
-filter_complex "
[0:v]trim=0:5,setpts=PTS-STARTPTS[0v_1];
[1:v]loop=loop=25*3:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -&gt; fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=2:d=1[pause1];
[0:v]trim=5:10,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_2];
[2:v]loop=loop=25*4:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -&gt; fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=1[pause2];
[0:v]trim=10:15,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_3];
[3:v]loop=loop=25*5:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -&gt; fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=2[pause3];
[0:v]trim=15:20,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_4];
[4:v]loop=loop=25*6:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -&gt; fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=3[pause4];
[0:v]trim=20:25,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_5];
[5:v]loop=loop=25*7:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -&gt; fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=4[pause5];
[0:v]trim=25:30,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_6];
[6:v]loop=loop=25*5:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -&gt; fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=2[pause6];
[0:v]trim=30:35,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_7];
[7:v]loop=loop=25*3:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -&gt; fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=2:d=1[pause7];
[0:v]trim=35,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_8];

[0v_1][pause1]
[0v_2][pause2]
[0v_3][pause3]
[0v_4][pause4]
[0v_5][pause5]
[0v_6][pause6]
[0v_7][pause7]
[0v_8]
concat=n=15:a=0:v=1[v]
" -map '[v]' -an "freeze.mp4"
</code></pre>

<p>And here is the whole log (truncating some initial logs for PNG saving due to size limit):</p>

<pre><code>ffmpeg version N-48722-gac551c54b1-static https://johnvansickle.com/ffmpeg/  Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 6.3.0 (Debian 6.3.0-18+deb9u1) 20170516
  configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg
  libavutil      56. 26.100 / 56. 26.100
  libavcodec     58. 52.100 / 58. 52.100
  libavformat    58. 27.103 / 58. 27.103
  libavdevice    58.  7.100 / 58.  7.100
  libavfilter     7. 50.100 /  7. 50.100
  libswscale      5.  4.100 /  5.  4.100
  libswresample   3.  4.100 /  3.  4.100
  libpostproc    55.  4.100 / 55.  4.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'sample.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
  Duration: 00:00:45.02, start: 0.000000, bitrate: 1242 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], 1105 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
Stream mapping:
  Stream #0:0 -&gt; #0:0 (h264 (native) -&gt; png (native))
Press [q] to stop, [?] for help
Output #0, image2, to '_25.png':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
    Stream #0:0(und): Video: png, rgb24, 720x480 [SAR 8:9 DAR 4:3], q=2-31, 200 kb/s, 1 fps, 1 tbn, 1 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
      encoder         : Lavc58.52.100 png
frame=    1 fps=0.8 q=-0.0 Lsize=N/A time=00:00:01.00 bitrate=N/A speed=0.817x
video:663kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
ffmpeg version N-48722-gac551c54b1-static https://johnvansickle.com/ffmpeg/  Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 6.3.0 (Debian 6.3.0-18+deb9u1) 20170516
  configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg
  libavutil      56. 26.100 / 56. 26.100
  libavcodec     58. 52.100 / 58. 52.100
  libavformat    58. 27.103 / 58. 27.103
  libavdevice    58.  7.100 / 58.  7.100
  libavfilter     7. 50.100 /  7. 50.100
  libswscale      5.  4.100 /  5.  4.100
  libswresample   3.  4.100 /  3.  4.100
  libpostproc    55.  4.100 / 55.  4.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'sample.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
  Duration: 00:00:45.02, start: 0.000000, bitrate: 1242 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], 1105 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
Stream mapping:
  Stream #0:0 -&gt; #0:0 (h264 (native) -&gt; png (native))
Press [q] to stop, [?] for help
Output #0, image2, to '_30.png':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
    Stream #0:0(und): Video: png, rgb24, 720x480 [SAR 8:9 DAR 4:3], q=2-31, 200 kb/s, 1 fps, 1 tbn, 1 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
      encoder         : Lavc58.52.100 png
frame=    1 fps=0.7 q=-0.0 Lsize=N/A time=00:00:01.00 bitrate=N/A speed=0.715x
video:503kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
ffmpeg version N-48722-gac551c54b1-static https://johnvansickle.com/ffmpeg/  Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 6.3.0 (Debian 6.3.0-18+deb9u1) 20170516
  configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg
  libavutil      56. 26.100 / 56. 26.100
  libavcodec     58. 52.100 / 58. 52.100
  libavformat    58. 27.103 / 58. 27.103
  libavdevice    58.  7.100 / 58.  7.100
  libavfilter     7. 50.100 /  7. 50.100
  libswscale      5.  4.100 /  5.  4.100
  libswresample   3.  4.100 /  3.  4.100
  libpostproc    55.  4.100 / 55.  4.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'sample.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
  Duration: 00:00:45.02, start: 0.000000, bitrate: 1242 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], 1105 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
Stream mapping:
  Stream #0:0 -&gt; #0:0 (h264 (native) -&gt; png (native))
Press [q] to stop, [?] for help
Output #0, image2, to '_35.png':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
    Stream #0:0(und): Video: png, rgb24, 720x480 [SAR 8:9 DAR 4:3], q=2-31, 200 kb/s, 1 fps, 1 tbn, 1 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
      encoder         : Lavc58.52.100 png
frame=    1 fps=0.6 q=-0.0 Lsize=N/A time=00:00:01.00 bitrate=N/A speed=0.637x
video:539kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
ffmpeg version N-48722-gac551c54b1-static https://johnvansickle.com/ffmpeg/  Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 6.3.0 (Debian 6.3.0-18+deb9u1) 20170516
  configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg
  libavutil      56. 26.100 / 56. 26.100
  libavcodec     58. 52.100 / 58. 52.100
  libavformat    58. 27.103 / 58. 27.103
  libavdevice    58.  7.100 / 58.  7.100
  libavfilter     7. 50.100 /  7. 50.100
  libswscale      5.  4.100 /  5.  4.100
  libswresample   3.  4.100 /  3.  4.100
  libpostproc    55.  4.100 / 55.  4.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'sample.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
  Duration: 00:00:45.02, start: 0.000000, bitrate: 1242 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], 1105 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
Input #1, png_pipe, from '_05.png':
  Duration: N/A, bitrate: N/A
    Stream #1:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #2, png_pipe, from '_10.png':
  Duration: N/A, bitrate: N/A
    Stream #2:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #3, png_pipe, from '_15.png':
  Duration: N/A, bitrate: N/A
    Stream #3:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #4, png_pipe, from '_20.png':
  Duration: N/A, bitrate: N/A
    Stream #4:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #5, png_pipe, from '_25.png':
  Duration: N/A, bitrate: N/A
    Stream #5:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #6, png_pipe, from '_30.png':
  Duration: N/A, bitrate: N/A
    Stream #6:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #7, png_pipe, from '_35.png':
  Duration: N/A, bitrate: N/A
    Stream #7:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
[Parsed_drawtext_3 @ 0x6b53ec0] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_9 @ 0x6b5de40] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_15 @ 0x6a1a780] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_21 @ 0x6a11940] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_27 @ 0x6b59f40] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_33 @ 0x6a12880] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_39 @ 0x698d740] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
Stream mapping:
  Stream #0:0 (h264) -&gt; trim
  Stream #0:0 (h264) -&gt; trim
  Stream #0:0 (h264) -&gt; trim
  Stream #0:0 (h264) -&gt; trim
  Stream #0:0 (h264) -&gt; trim
  Stream #0:0 (h264) -&gt; trim
  Stream #0:0 (h264) -&gt; trim
  Stream #0:0 (h264) -&gt; trim
  Stream #1:0 (png) -&gt; loop
  Stream #2:0 (png) -&gt; loop
  Stream #3:0 (png) -&gt; loop
  Stream #4:0 (png) -&gt; loop
  Stream #5:0 (png) -&gt; loop
  Stream #6:0 (png) -&gt; loop
  Stream #7:0 (png) -&gt; loop
  concat -&gt; Stream #0:0 (libx264)
Press [q] to stop, [?] for help
[Parsed_drawtext_3 @ 0x6f3e480] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_9 @ 0x6f4ec00] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_15 @ 0x6f57e00] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_21 @ 0x6f65600] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_27 @ 0x6f6ed00] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_33 @ 0x6f79c40] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_39 @ 0x6f84dc0] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[libx264 @ 0x68fb900] using SAR=8/9
[libx264 @ 0x68fb900] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
[libx264 @ 0x68fb900] profile Progressive High, level 3.0, 4:2:0, 8-bit
[libx264 @ 0x68fb900] 264 - core 157 r2969 d4099dd - H.264/MPEG-4 AVC codec - Copyleft 2003-2019 - 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=12 lookahead_threads=2 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 'freeze.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
    Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], q=-1--1, 29.97 fps, 30k tbn, 29.97 tbc (default)
    Metadata:
      encoder         : Lavc58.52.100 libx264
    Side data:
      cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
frame= 1351 fps= 75 q=-1.0 Lsize=    5080kB time=00:00:44.97 bitrate= 925.2kbits/s dup=0 drop=5 speed=2.49x
video:5064kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.321138%
[libx264 @ 0x68fb900] frame I:19    Avg QP:18.75  size: 30579
[libx264 @ 0x68fb900] frame P:424   Avg QP:22.86  size:  7793
[libx264 @ 0x68fb900] frame B:908   Avg QP:26.77  size:  1431
[libx264 @ 0x68fb900] consecutive B-frames:  5.8% 11.5%  6.2% 76.4%
[libx264 @ 0x68fb900] mb I  I16..4: 11.1% 63.3% 25.6%
[libx264 @ 0x68fb900] mb P  I16..4:  1.6%  6.2%  1.0%  P16..4: 45.2% 16.3%  8.6%  0.0%  0.0%    skip:21.0%
[libx264 @ 0x68fb900] mb B  I16..4:  0.3%  0.5%  0.1%  B16..8: 33.2%  3.4%  0.6%  direct: 1.3%  skip:60.6%  L0:47.5% L1:46.2% BI: 6.3%
[libx264 @ 0x68fb900] 8x8 transform intra:66.7% inter:72.0%
[libx264 @ 0x68fb900] coded y,uvDC,uvAC intra: 52.5% 70.2% 34.8% inter: 11.4% 19.5% 0.9%
[libx264 @ 0x68fb900] i16 v,h,dc,p: 55% 14% 10% 22%
[libx264 @ 0x68fb900] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 28% 13% 22%  5%  6%  8%  6%  7%  5%
[libx264 @ 0x68fb900] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 23% 14% 12%  7% 10% 10%  8%  8%  7%
[libx264 @ 0x68fb900] i8c dc,h,v,p: 52% 15% 26%  7%
[libx264 @ 0x68fb900] Weighted P-Frames: Y:23.3% UV:21.0%
[libx264 @ 0x68fb900] ref P L0: 67.4% 15.6% 13.4%  3.5%  0.2%
[libx264 @ 0x68fb900] ref B L0: 92.2%  6.5%  1.3%
[libx264 @ 0x68fb900] ref B L1: 98.2%  1.8%
[libx264 @ 0x68fb900] kb/s:920.11
</code></pre>

CC BY-SA 4.0
2019-05-01T06:45:38.040Z
Why `size=2`? Each input is one image.
Gyan
CC BY-SA 4.0
2019-05-01T14:40:23.100Z
Heh thanks. That solved the problem. I got the code from somewhere else!
angel_30
CC BY-SA 4.0
2019-05-01T21:10:11.420Z
@Gyan do you happen to know what is the license for freezedetect filter? Can we use it from the source code?
angel_30
CC BY-SA 4.0
2019-05-02T04:48:59.847Z
freezedetect is LGPL 2.1. By source code, do you mean via C API?
Gyan
CC BY-SA 4.0
2019-05-02T15:00:56.597Z
@Gyan yes via C API.
angel_30
<video><ffmpeg><video-editor><encoding>
FFmpeg loop filter doesn't work
angel_30
# FFmpeg loop filter doesn't work

(Asked by: username_0 on 2019-04-30)

This is a follow-up from my previous question here. Basically, I'm trying to use FFmpeg's loop filter to freeze some frames and insert black frames. It's very weird; I swear it was working a few days ago, but now only the blackframe insertion works, the freezing frames doesn't work. So just no frozen frames inside. I don't know what's going wrong?!
Here is my command. I also updated my ffmpeg to the latest version just now:
fn="sample.mp4"

#
ffmpeg -y -i "${fn}" -ss 00:00:05 -to 00:00:06 -r 1/1 _05.png
ffmpeg -y -i "${fn}" -ss 00:00:10 -to 00:00:11 -r 1/1 _10.png
ffmpeg -y -i "${fn}" -ss 00:00:15 -to 00:00:16 -r 1/1 _15.png
ffmpeg -y -i "${fn}" -ss 00:00:20 -to 00:00:21 -r 1/1 _20.png
ffmpeg -y -i "${fn}" -ss 00:00:25 -to 00:00:26 -r 1/1 _25.png
ffmpeg -y -i "${fn}" -ss 00:00:30 -to 00:00:31 -r 1/1 _30.png
ffmpeg -y -i "${fn}" -ss 00:00:35 -to 00:00:36 -r 1/1 _35.png

#
ffmpeg -y -i "${fn}" \
-i _05.png \
-i _10.png \
-i _15.png \
-i _20.png \
-i _25.png \
-i _30.png \
-i _35.png \
-filter_complex "
[0:v]trim=0:5,setpts=PTS-STARTPTS[0v_1];
[1:v]loop=loop=25*3:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -> fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=2:d=1[pause1];
[0:v]trim=5:10,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_2];
[2:v]loop=loop=25*4:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -> fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=1[pause2];
[0:v]trim=10:15,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_3];
[3:v]loop=loop=25*5:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -> fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=2[pause3];
[0:v]trim=15:20,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_4];
[4:v]loop=loop=25*6:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -> fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=3[pause4];
[0:v]trim=20:25,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_5];
[5:v]loop=loop=25*7:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -> fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=4[pause5];
[0:v]trim=25:30,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_6];
[6:v]loop=loop=25*5:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -> fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=3:d=2[pause6];
[0:v]trim=30:35,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_7];
[7:v]loop=loop=25*3:size=2
,drawtext='fontsize=40:fontcolor=0x0000FF@0.7
:text=pause -> fade-out':x=920:y=20:shadowcolor=black@0.7:shadowx=1:shadowy=1
,fade=t=out:st=2:d=1[pause7];
[0:v]trim=35,setpts=PTS-STARTPTS
,fade=t=in:d=1[0v_8];

[0v_1][pause1]
[0v_2][pause2]
[0v_3][pause3]
[0v_4][pause4]
[0v_5][pause5]
[0v_6][pause6]
[0v_7][pause7]
[0v_8]
concat=n=15:a=0:v=1[v]
" -map '[v]' -an "freeze.mp4"

And here is the whole log (truncating some initial logs for PNG saving due to size limit):
ffmpeg version N-48722-gac551c54b1-static https://johnvansickle.com/ffmpeg/  Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 6.3.0 (Debian 6.3.0-18+deb9u1) 20170516
  configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg
  libavutil      56. 26.100 / 56. 26.100
  libavcodec     58. 52.100 / 58. 52.100
  libavformat    58. 27.103 / 58. 27.103
  libavdevice    58.  7.100 / 58.  7.100
  libavfilter     7. 50.100 /  7. 50.100
  libswscale      5.  4.100 /  5.  4.100
  libswresample   3.  4.100 /  3.  4.100
  libpostproc    55.  4.100 / 55.  4.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'sample.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
  Duration: 00:00:45.02, start: 0.000000, bitrate: 1242 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], 1105 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> png (native))
Press [q] to stop, [?] for help
Output #0, image2, to '_25.png':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
    Stream #0:0(und): Video: png, rgb24, 720x480 [SAR 8:9 DAR 4:3], q=2-31, 200 kb/s, 1 fps, 1 tbn, 1 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
      encoder         : Lavc58.52.100 png
frame=    1 fps=0.8 q=-0.0 Lsize=N/A time=00:00:01.00 bitrate=N/A speed=0.817x
video:663kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
ffmpeg version N-48722-gac551c54b1-static https://johnvansickle.com/ffmpeg/  Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 6.3.0 (Debian 6.3.0-18+deb9u1) 20170516
  configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg
  libavutil      56. 26.100 / 56. 26.100
  libavcodec     58. 52.100 / 58. 52.100
  libavformat    58. 27.103 / 58. 27.103
  libavdevice    58.  7.100 / 58.  7.100
  libavfilter     7. 50.100 /  7. 50.100
  libswscale      5.  4.100 /  5.  4.100
  libswresample   3.  4.100 /  3.  4.100
  libpostproc    55.  4.100 / 55.  4.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'sample.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
  Duration: 00:00:45.02, start: 0.000000, bitrate: 1242 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], 1105 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> png (native))
Press [q] to stop, [?] for help
Output #0, image2, to '_30.png':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
    Stream #0:0(und): Video: png, rgb24, 720x480 [SAR 8:9 DAR 4:3], q=2-31, 200 kb/s, 1 fps, 1 tbn, 1 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
      encoder         : Lavc58.52.100 png
frame=    1 fps=0.7 q=-0.0 Lsize=N/A time=00:00:01.00 bitrate=N/A speed=0.715x
video:503kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
ffmpeg version N-48722-gac551c54b1-static https://johnvansickle.com/ffmpeg/  Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 6.3.0 (Debian 6.3.0-18+deb9u1) 20170516
  configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg
  libavutil      56. 26.100 / 56. 26.100
  libavcodec     58. 52.100 / 58. 52.100
  libavformat    58. 27.103 / 58. 27.103
  libavdevice    58.  7.100 / 58.  7.100
  libavfilter     7. 50.100 /  7. 50.100
  libswscale      5.  4.100 /  5.  4.100
  libswresample   3.  4.100 /  3.  4.100
  libpostproc    55.  4.100 / 55.  4.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'sample.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
  Duration: 00:00:45.02, start: 0.000000, bitrate: 1242 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], 1105 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
Stream mapping:
  Stream #0:0 -> #0:0 (h264 (native) -> png (native))
Press [q] to stop, [?] for help
Output #0, image2, to '_35.png':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
    Stream #0:0(und): Video: png, rgb24, 720x480 [SAR 8:9 DAR 4:3], q=2-31, 200 kb/s, 1 fps, 1 tbn, 1 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
      encoder         : Lavc58.52.100 png
frame=    1 fps=0.6 q=-0.0 Lsize=N/A time=00:00:01.00 bitrate=N/A speed=0.637x
video:539kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
ffmpeg version N-48722-gac551c54b1-static https://johnvansickle.com/ffmpeg/  Copyright (c) 2000-2019 the FFmpeg developers
  built with gcc 6.3.0 (Debian 6.3.0-18+deb9u1) 20170516
  configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gmp --enable-gray --enable-libaom --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora --enable-libvidstab --enable-libvo-amrwbenc --enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libdav1d --enable-libxvid --enable-libzvbi --enable-libzimg
  libavutil      56. 26.100 / 56. 26.100
  libavcodec     58. 52.100 / 58. 52.100
  libavformat    58. 27.103 / 58. 27.103
  libavdevice    58.  7.100 / 58.  7.100
  libavfilter     7. 50.100 /  7. 50.100
  libswscale      5.  4.100 /  5.  4.100
  libswresample   3.  4.100 /  3.  4.100
  libpostproc    55.  4.100 / 55.  4.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'sample.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
  Duration: 00:00:45.02, start: 0.000000, bitrate: 1242 kb/s
    Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], 1105 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
    Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 128 kb/s (default)
    Metadata:
      handler_name    : SoundHandler
    Stream #0:2(eng): Data: none (tmcd / 0x64636D74)
    Metadata:
      handler_name    : VideoHandler
      timecode        : 00:59:55:12
Input #1, png_pipe, from '_05.png':
  Duration: N/A, bitrate: N/A
    Stream #1:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #2, png_pipe, from '_10.png':
  Duration: N/A, bitrate: N/A
    Stream #2:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #3, png_pipe, from '_15.png':
  Duration: N/A, bitrate: N/A
    Stream #3:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #4, png_pipe, from '_20.png':
  Duration: N/A, bitrate: N/A
    Stream #4:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #5, png_pipe, from '_25.png':
  Duration: N/A, bitrate: N/A
    Stream #5:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #6, png_pipe, from '_30.png':
  Duration: N/A, bitrate: N/A
    Stream #6:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
Input #7, png_pipe, from '_35.png':
  Duration: N/A, bitrate: N/A
    Stream #7:0: Video: png, rgb24(pc), 720x480 [SAR 8:9 DAR 4:3], 25 tbr, 25 tbn, 25 tbc
[Parsed_drawtext_3 @ 0x6b53ec0] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_9 @ 0x6b5de40] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_15 @ 0x6a1a780] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_21 @ 0x6a11940] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_27 @ 0x6b59f40] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_33 @ 0x6a12880] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_39 @ 0x698d740] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
Stream mapping:
  Stream #0:0 (h264) -> trim
  Stream #0:0 (h264) -> trim
  Stream #0:0 (h264) -> trim
  Stream #0:0 (h264) -> trim
  Stream #0:0 (h264) -> trim
  Stream #0:0 (h264) -> trim
  Stream #0:0 (h264) -> trim
  Stream #0:0 (h264) -> trim
  Stream #1:0 (png) -> loop
  Stream #2:0 (png) -> loop
  Stream #3:0 (png) -> loop
  Stream #4:0 (png) -> loop
  Stream #5:0 (png) -> loop
  Stream #6:0 (png) -> loop
  Stream #7:0 (png) -> loop
  concat -> Stream #0:0 (libx264)
Press [q] to stop, [?] for help
[Parsed_drawtext_3 @ 0x6f3e480] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_9 @ 0x6f4ec00] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_15 @ 0x6f57e00] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_21 @ 0x6f65600] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_27 @ 0x6f6ed00] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_33 @ 0x6f79c40] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[Parsed_drawtext_39 @ 0x6f84dc0] Using "/usr/share/fonts/dejavu/DejaVuSans.ttf"
[libx264 @ 0x68fb900] using SAR=8/9
[libx264 @ 0x68fb900] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 BMI2 AVX2
[libx264 @ 0x68fb900] profile Progressive High, level 3.0, 4:2:0, 8-bit
[libx264 @ 0x68fb900] 264 - core 157 r2969 d4099dd - H.264/MPEG-4 AVC codec - Copyleft 2003-2019 - 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=12 lookahead_threads=2 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 'freeze.mp4':
  Metadata:
    major_brand     : isom
    minor_version   : 512
    compatible_brands: isomiso2avc1mp41
    encoder         : Lavf58.27.103
    Stream #0:0: Video: h264 (libx264) (avc1 / 0x31637661), yuv420p, 720x480 [SAR 8:9 DAR 4:3], q=-1--1, 29.97 fps, 30k tbn, 29.97 tbc (default)
    Metadata:
      encoder         : Lavc58.52.100 libx264
    Side data:
      cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
frame= 1351 fps= 75 q=-1.0 Lsize=    5080kB time=00:00:44.97 bitrate= 925.2kbits/s dup=0 drop=5 speed=2.49x
video:5064kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.321138%
[libx264 @ 0x68fb900] frame I:19    Avg QP:18.75  size: 30579
[libx264 @ 0x68fb900] frame P:424   Avg QP:22.86  size:  7793
[libx264 @ 0x68fb900] frame B:908   Avg QP:26.77  size:  1431
[libx264 @ 0x68fb900] consecutive B-frames:  5.8% 11.5%  6.2% 76.4%
[libx264 @ 0x68fb900] mb I  I16..4: 11.1% 63.3% 25.6%
[libx264 @ 0x68fb900] mb P  I16..4:  1.6%  6.2%  1.0%  P16..4: 45.2% 16.3%  8.6%  0.0%  0.0%    skip:21.0%
[libx264 @ 0x68fb900] mb B  I16..4:  0.3%  0.5%  0.1%  B16..8: 33.2%  3.4%  0.6%  direct: 1.3%  skip:60.6%  L0:47.5% L1:46.2% BI: 6.3%
[libx264 @ 0x68fb900] 8x8 transform intra:66.7% inter:72.0%
[libx264 @ 0x68fb900] coded y,uvDC,uvAC intra: 52.5% 70.2% 34.8% inter: 11.4% 19.5% 0.9%
[libx264 @ 0x68fb900] i16 v,h,dc,p: 55% 14% 10% 22%
[libx264 @ 0x68fb900] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 28% 13% 22%  5%  6%  8%  6%  7%  5%
[libx264 @ 0x68fb900] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 23% 14% 12%  7% 10% 10%  8%  8%  7%
[libx264 @ 0x68fb900] i8c dc,h,v,p: 52% 15% 26%  7%
[libx264 @ 0x68fb900] Weighted P-Frames: Y:23.3% UV:21.0%
[libx264 @ 0x68fb900] ref P L0: 67.4% 15.6% 13.4%  3.5%  0.2%
[libx264 @ 0x68fb900] ref B L0: 92.2%  6.5%  1.3%
[libx264 @ 0x68fb900] ref B L1: 98.2%  1.8%
[libx264 @ 0x68fb900] kb/s:920.11

**Tags:** video, ffmpeg, video-editor, encoding

> **Comments:**
> **username_1**: Why `size=2`? Each input is one image.  
> **username_0**: Heh thanks. That solved the problem. I got the code from somewhere else!  
> **username_0**: @username_1 do you happen to know what is the license for freezedetect filter? Can we use it from the source code?  
> **username_1**: freezedetect is LGPL 2.1. By source code, do you mean via C API?  
> **username_0**: @username_1 yes via C API.  

---

## 0 answers

