Recherche avancée

Médias (2)

Mot : - Tags -/documentation

Autres articles (36)

  • Des sites réalisés avec MediaSPIP

    2 mai 2011, par

    Cette page présente quelques-uns des sites fonctionnant sous MediaSPIP.
    Vous pouvez bien entendu ajouter le votre grâce au formulaire en bas de page.

  • Support audio et vidéo HTML5

    10 avril 2011

    MediaSPIP utilise les balises HTML5 video et audio pour la lecture de documents multimedia en profitant des dernières innovations du W3C supportées par les navigateurs modernes.
    Pour les navigateurs plus anciens, le lecteur flash Flowplayer est utilisé.
    Le lecteur HTML5 utilisé a été spécifiquement créé pour MediaSPIP : il est complètement modifiable graphiquement pour correspondre à un thème choisi.
    Ces technologies permettent de distribuer vidéo et son à la fois sur des ordinateurs conventionnels (...)

  • HTML5 audio and video support

    13 avril 2011, par

    MediaSPIP uses HTML5 video and audio tags to play multimedia files, taking advantage of the latest W3C innovations supported by modern browsers.
    The MediaSPIP player used has been created specifically for MediaSPIP and can be easily adapted to fit in with a specific theme.
    For older browsers the Flowplayer flash fallback is used.
    MediaSPIP allows for media playback on major mobile platforms with the above (...)

Sur d’autres sites (2986)

  • FFMPEG : custom sequence input images

    14 juillet 2016, par gabber

    I created a video from a set of images.

    The command look like :

    ffmpeg -i bg.jpeg -i img_%d.png -filter_complex overlay=5:H-h-5[b]-shortest testvid.mp4

    Problem :

    The input -i img_%d.png means img_0.png, img_1.png, img_2.png, ...

    But I have custom sequence like this : {img_0.png, img_1.png, img_1.png, img_2.png, img_1.png, img5.png, img_4.png}

    Question :

    Can I put my image sequence into input of ffmpeg ?

    Updated

    cmd :

    ffmpeg -i bg.jpeg -f concat -fflags +genpts -i test.txt -filter_complex overlay=5:H-h-5 -shortest testvid.mp4

    output :

    ffmpeg version 3.1.1 Copyright (c) 2000-2016 the FFmpeg developers
     built with gcc 4.8 (Ubuntu 4.8.4-2ubuntu1~14.04.3)
     configuration: --enable-gpl --enable-libx264 --enable-libfreetype
     libavutil      55. 28.100 / 55. 28.100
     libavcodec     57. 48.101 / 57. 48.101
     libavformat    57. 41.100 / 57. 41.100
     libavdevice    57.  0.101 / 57.  0.101
     libavfilter     6. 47.100 /  6. 47.100
     libswscale      4.  1.100 /  4.  1.100
     libswresample   2.  1.100 /  2.  1.100
     libpostproc    54.  0.100 / 54.  0.100
    Input #0, image2, from 'bg.jpeg':
     Duration: 00:00:00.04, start: 0.000000, bitrate: 47329 kb/s
       Stream #0:0: Video: mjpeg, yuvj420p(pc, bt470bg/unknown/unknown), 600x800 [SAR 1:1 DAR 3:4], 25 tbr, 25 tbn, 25 tbc
    Input #1, concat, from 'test.txt':
     Duration: N/A, start: 0.000000, bitrate: N/A
       Stream #1:0: Video: png, pal8(pc), 200x200, 25 tbr, 25 tbn, 25 tbc
    File 'testvid.mp4' already exists. Overwrite ? [y/N] y
    [swscaler @ 0x2a18360] deprecated pixel format used, make sure you did set range correctly
    [libx264 @ 0x2a05d80] using SAR=1/1
    [libx264 @ 0x2a05d80] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2 AVX FMA3 AVX2 LZCNT BMI2
    [libx264 @ 0x2a05d80] profile High, level 3.1
    [libx264 @ 0x2a05d80] 264 - core 148 r2705 3f5ed56 - 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
    [mp4 @ 0x2a04b20] Using AVStream.codec to pass codec parameters to muxers is deprecated, use AVStream.codecpar instead.
    Output #0, mp4, to 'testvid.mp4':
     Metadata:
       encoder         : Lavf57.41.100
       Stream #0:0: Video: h264 (libx264) ([33][0][0][0] / 0x0021), yuv420p, 600x800 [SAR 1:1 DAR 3:4], q=-1--1, 25 fps, 12800 tbn, 25 tbc (default)
       Metadata:
         encoder         : Lavc57.48.101 libx264
       Side data:
         cpb: bitrate max/min/avg: 0/0/0 buffer size: 0 vbv_delay: -1
    Stream mapping:
     Stream #0:0 (mjpeg) -> overlay:main
     Stream #1:0 (png) -> overlay:overlay
     overlay -> Stream #0:0 (libx264)
    Press [q] to stop, [?] for help
    [concat @ 0x29e2400] DTS -230575710986777 < 0 out of order
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    DTS -230575710986777, next:40000 st:0 invalid dropping
    PTS -230575710986777, next:40000 invalid dropping st:0
    frame=    4 fps=0.0 q=-1.0 Lsize=      39kB time=00:00:00.04 bitrate=8050.9kbits/s dup=0 drop=65 speed=0.516x    
    video:39kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 2.222729%
    [libx264 @ 0x2a05d80] frame I:1     Avg QP:24.64  size: 37536
    [libx264 @ 0x2a05d80] frame P:1     Avg QP:27.18  size:  1085
    [libx264 @ 0x2a05d80] frame B:2     Avg QP:29.93  size:    73
    [libx264 @ 0x2a05d80] consecutive B-frames: 25.0%  0.0% 75.0%  0.0%
    [libx264 @ 0x2a05d80] mb I  I16..4:  1.7% 86.1% 12.2%
    [libx264 @ 0x2a05d80] mb P  I16..4:  0.0%  0.0%  0.0%  P16..4:  1.7%  1.3%  1.5%  0.0%  0.0%    skip:95.5%
    [libx264 @ 0x2a05d80] mb B  I16..4:  0.0%  0.0%  0.0%  B16..8:  2.4%  0.0%  0.0%  direct: 0.0%  skip:97.6%  L0:62.6% L1:37.4% BI: 0.0%
    [libx264 @ 0x2a05d80] 8x8 transform intra:86.1% inter:33.9%
    [libx264 @ 0x2a05d80] coded y,uvDC,uvAC intra: 91.5% 84.4% 38.5% inter: 0.6% 0.4% 0.1%
    [libx264 @ 0x2a05d80] i16 v,h,dc,p:  9% 12%  3% 76%
    [libx264 @ 0x2a05d80] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 24% 19% 17%  8%  4%  5%  5%  7% 10%
    [libx264 @ 0x2a05d80] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 22% 18% 10% 10%  9%  7% 10%  8%  7%
    [libx264 @ 0x2a05d80] i8c dc,h,v,p: 45% 21% 26%  8%
    [libx264 @ 0x2a05d80] Weighted P-Frames: Y:0.0% UV:0.0%
    [libx264 @ 0x2a05d80] ref B L0: 84.2% 15.8%
    [libx264 @ 0x2a05d80] kb/s:1938.35
  • How to save rtsp stream without packet loss by using FFMPEG

    19 juillet 2016, par sumit singh

    I am saving stream of live camera by using FFMPEG. When i am trying to save the video some data packets are loss so the video is not playing properly.I am using following FFMPEG Library

    The command which i am sending is-

    String[] cmd = {"-y", "-i", "rtsp://wowzaec2demo.streamlock.net/vod/mp4:BigBuckBunny_115k.mov", "-c:v", "libx264", "-acodec", "aac","-t", time, file_path};
    execFFmpegBinary(cmd);

    I am also try this command but the result is same

    String[] cmd = { "-y", "-rtsp_transport", "tcp", "-i",  "rtsp://wowzaec2demo.streamlock.net/vod/mp4:BigBuckBunny_115k.mov", "-c:v", "libx264", "-preset", "slow", "-b:v", "500k", "-maxrate", "500k", "-bufsize", "3000k", "-vf", "scale=-1:480", "-threads", "0", "-codec:a", "libfdk_aac", "-b:a", "128k", "-t", time, file_path};

    Here is the log of command output-

    07-15 15:16:55.180 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:55.180 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 455 packets
           07-15 15:16:55.190 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:55.190 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 16 packets
           07-15 15:16:55.300 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:55.300 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 13 packets
           07-15 15:16:55.310 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45c42680] mb_type 58 in P slice too large at 31 16
           07-15 15:16:55.320 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45c42680] error while decoding MB 31 16
           07-15 15:16:55.330 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45c42680] concealing 918 DC, 918 AC, 918 MV errors in P frame
           07-15 15:16:55.330 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:55.330 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 55 packets
           07-15 15:16:55.340 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:55.340 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 19 packets
           07-15 15:16:55.340 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:55.350 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 1 packets
           07-15 15:16:55.350 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x458737c0] out of range intra chroma pred mode at 7 28
           07-15 15:16:55.350 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x458737c0] error while decoding MB 7 28
           07-15 15:16:55.360 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x458737c0] concealing 402 DC, 402 AC, 402 MV errors in P frame
           07-15 15:16:55.360 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] P sub_mb_type 8 out of range at 28 14
           07-15 15:16:55.370 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] error while decoding MB 28 14
           07-15 15:16:55.370 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] concealing 1011 DC, 1011 AC, 1011 MV errors in P frame
           07-15 15:16:55.380 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45afe200] cbp too large (132) at 12 20
           07-15 15:16:55.380 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45afe200] error while decoding MB 12 20
           07-15 15:16:55.390 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45afe200] concealing 757 DC, 757 AC, 757 MV errors in P frame
           07-15 15:16:55.640 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  173 fps=3.6 q=28.0 size=     657kB time=00:00:23.84 bitrate= 225.8kbits/s speed=0.502x
           07-15 15:16:55.840 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:55.910 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 520 packets
           07-15 15:16:55.920 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:55.920 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 2 packets
           07-15 15:16:55.920 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:55.920 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 56 packets
           07-15 15:16:55.930 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x4581bb60] concealing 800 DC, 800 AC, 800 MV errors in P frame
           07-15 15:16:56.010 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45c42680] concealing 311 DC, 311 AC, 311 MV errors in P frame
           07-15 15:16:56.720 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  174 fps=3.6 q=28.0 size=     674kB time=00:00:23.88 bitrate= 231.0kbits/s speed=0.497x
           07-15 15:16:57.050 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  175 fps=3.6 q=28.0 size=     675kB time=00:00:29.00 bitrate= 190.6kbits/s speed=0.596x
           07-15 15:16:57.350 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  177 fps=3.6 q=28.0 size=     686kB time=00:00:30.36 bitrate= 185.1kbits/s speed=0.617x
           07-15 15:16:58.610 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  182 fps=3.6 q=28.0 size=     703kB time=00:00:30.56 bitrate= 188.3kbits/s speed=0.609x
           07-15 15:16:59.120 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:59.120 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 23 packets
           07-15 15:16:59.190 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  184 fps=3.6 q=28.0 size=     709kB time=00:00:30.64 bitrate= 189.6kbits/s speed=0.602x
           07-15 15:16:59.200 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45c42680] concealing 69 DC, 69 AC, 69 MV errors in P frame
           07-15 15:16:59.370 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:59.440 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 35 packets
           07-15 15:16:59.440 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x458737c0] concealing 338 DC, 338 AC, 338 MV errors in I frame
           07-15 15:16:59.920 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  187 fps=3.6 q=28.0 size=     716kB time=00:00:30.76 bitrate= 190.7kbits/s speed=0.595x
           07-15 15:16:59.920 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:16:59.990 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 20 packets
           07-15 15:16:59.990 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45afe200] concealing 489 DC, 489 AC, 489 MV errors in P frame
           07-15 15:17:01.980 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  190 fps=3.5 q=28.0 size=     737kB time=00:00:30.88 bitrate= 195.4kbits/s speed=0.575x
           07-15 15:17:01.980 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:01.980 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 35 packets
           07-15 15:17:02.060 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:02.060 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 10 packets
           07-15 15:17:02.230 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:02.230 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 10 packets
           07-15 15:17:02.270 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] dquant out of range (124) at 15 35
           07-15 15:17:02.270 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] error while decoding MB 15 35
           07-15 15:17:02.280 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] concealing 79 DC, 79 AC, 79 MV errors in P frame
           07-15 15:17:02.280 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:02.280 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 76 packets
           07-15 15:17:02.290 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45c42680] concealing 805 DC, 805 AC, 805 MV errors in P frame
           07-15 15:17:02.510 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:02.510 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 40 packets
           07-15 15:17:02.600 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  194 fps=3.6 q=28.0 size=     747kB time=00:00:31.04 bitrate= 197.1kbits/s speed=0.57x
           07-15 15:17:02.610 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:02.610 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 60 packets
           07-15 15:17:02.610 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x458737c0] concealing 526 DC, 526 AC, 526 MV errors in P frame
           07-15 15:17:02.620 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x4581bb60] concealing 197 DC, 197 AC, 197 MV errors in P frame
           07-15 15:17:03.380 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  195 fps=3.5 q=28.0 size=     751kB time=00:00:31.08 bitrate= 198.1kbits/s speed=0.562x
           07-15 15:17:03.570 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:03.640 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 474 packets
           07-15 15:17:03.640 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:03.650 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 109 packets
           07-15 15:17:03.650 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x4581bb60] negative number of zero coeffs at 28 22
           07-15 15:17:03.650 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x4581bb60] error while decoding MB 28 22
           07-15 15:17:03.660 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x4581bb60] concealing 651 DC, 651 AC, 651 MV errors in P frame
           07-15 15:17:03.660 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x458737c0] concealing 1074 DC, 1074 AC, 1074 MV errors in P frame
           07-15 15:17:03.920 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  195 fps=3.5 q=28.0 size=     751kB time=00:00:31.08 bitrate= 198.1kbits/s speed=0.557x
           07-15 15:17:05.530 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  199 fps=3.5 q=25.0 size=     766kB time=00:00:32.84 bitrate= 191.2kbits/s speed=0.573x
           07-15 15:17:06.250 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  202 fps=3.5 q=22.0 size=     784kB time=00:00:32.96 bitrate= 194.8kbits/s speed=0.568x
           07-15 15:17:07.130 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  205 fps=3.5 q=28.0 size=     800kB time=00:00:33.08 bitrate= 198.2kbits/s speed=0.562x
           07-15 15:17:08.960 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  207 fps=3.4 q=28.0 size=     811kB time=00:00:35.32 bitrate= 188.0kbits/s speed=0.581x
           07-15 15:17:09.560 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:09.560 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 133 packets
           07-15 15:17:09.660 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  210 fps=3.4 q=28.0 size=     817kB time=00:00:35.84 bitrate= 186.8kbits/s speed=0.584x
           07-15 15:17:09.670 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:09.670 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 14 packets
           07-15 15:17:09.680 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45c42680] concealing 410 DC, 410 AC, 410 MV errors in I frame
           07-15 15:17:09.770 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x4581bb60] concealing 72 DC, 72 AC, 72 MV errors in P frame
           07-15 15:17:10.730 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:10.730 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 24 packets
           07-15 15:17:10.740 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:10.740 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 56 packets
           07-15 15:17:11.410 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  212 fps=3.4 q=28.0 size=     819kB time=00:00:35.92 bitrate= 186.8kbits/s speed=0.574x
           07-15 15:17:11.510 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:11.510 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 14 packets
           07-15 15:17:11.510 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] concealing 77 DC, 77 AC, 77 MV errors in P frame
           07-15 15:17:11.520 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  213 fps=3.4 q=28.0 size=     820kB time=00:00:35.96 bitrate= 186.8kbits/s speed=0.568x
           07-15 15:17:11.520 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:11.520 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 10 packets
           07-15 15:17:11.670 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:11.720 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 82 packets
           07-15 15:17:11.730 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:11.730 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 41 packets
           07-15 15:17:11.740 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45c42680] concealing 1343 DC, 1343 AC, 1343 MV errors in I frame
           07-15 15:17:11.740 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:11.750 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 240 packets
           07-15 15:17:11.890 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:11.900 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 7 packets
           07-15 15:17:11.900 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:11.900 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 63 packets
           07-15 15:17:11.940 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] out of range intra chroma pred mode at 42 32
           07-15 15:17:11.950 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] error while decoding MB 42 32
           07-15 15:17:11.960 25713-25713/com.github.sampleffmpeg V/output: progress : [h264 @ 0x45ab8020] concealing 187 DC, 187 AC, 187 MV errors in P frame
           07-15 15:17:12.420 25713-25713/com.github.sampleffmpeg V/output: progress : [rtsp @ 0x420391c0] max delay reached. need to consume packet
           07-15 15:17:12.420 25713-25713/com.github.sampleffmpeg V/output: progress : [NULL @ 0x4203ba00] RTP: missed 9 packets
           07-15 15:17:12.830 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  217 fps=3.4 q=24.0 size=     881kB time=00:00:36.12 bitrate= 199.7kbits/s speed=0.562x
           07-15 15:17:32.710 25713-25713/com.github.sampleffmpeg V/output: progress : frame=  217 fps=2.6 q=-1.0 Lsize=    1192kB time=00:00:59.48 bitrate= 164.2kbits/s speed=0.703x
           07-15 15:17:32.720 25713-25713/com.github.sampleffmpeg V/output: progress : video:1190kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.207405%
           07-15 15:17:32.820 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] frame I:4     Avg QP:17.76  size: 23826
           07-15 15:17:32.820 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] frame P:141   Avg QP:20.25  size:  7361
           07-15 15:17:32.830 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] frame B:72    Avg QP:23.59  size:  1173
           07-15 15:17:32.830 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] consecutive B-frames: 54.4%  1.8%  6.9% 36.9%
           07-15 15:17:32.840 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] mb I  I16..4: 23.2% 42.9% 34.0%
           07-15 15:17:32.840 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] mb P  I16..4:  3.6%  3.2%  1.9%  P16..4: 27.9%  6.4%  4.8%  0.0%  0.0%    skip:52.3%
           07-15 15:17:32.850 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] mb B  I16..4:  0.1%  0.1%  0.0%  B16..8: 20.2%  1.0%  0.3%  direct: 1.1%  skip:77.2%  L0:42.5% L1:53.9% BI: 3.7%
           07-15 15:17:32.860 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] 8x8 transform intra:38.4% inter:29.9%
           07-15 15:17:32.860 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] coded y,uvDC,uvAC intra: 49.0% 31.1% 15.6% inter: 12.9% 10.5% 1.3%
           07-15 15:17:32.870 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] i16 v,h,dc,p: 72%  6%  5% 17%
           07-15 15:17:32.870 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 45% 16% 17%  2%  4%  3%  4%  5%  3%
           07-15 15:17:32.880 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 26% 19% 15%  5%  6%  4% 10%  9%  6%
           07-15 15:17:32.880 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] i8c dc,h,v,p: 46% 12% 40%  3%
           07-15 15:17:32.880 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] Weighted P-Frames: Y:0.0% UV:0.0%
           07-15 15:17:32.890 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] ref P L0: 78.9%  6.1%  9.5%  5.6%
           07-15 15:17:32.890 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] ref B L0: 87.4%  9.5%  3.1%
           07-15 15:17:32.890 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] ref B L1: 95.5%  4.5%
           07-15 15:17:32.900 25713-25713/com.github.sampleffmpeg V/output: progress : [libx264 @ 0x420a54c0] kb/s:163.45
           07-15 15:17:32.900 25713-25713/com.github.sampleffmpeg V/output: SUCCESS with output : ffmpeg version n3.0.1 Copyright (c) 2000-2016 the FFmpeg developers
           built with gcc 4.8 (GCC)
           configuration: --target-os=linux --cross-prefix=/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/bin/i686-linux-android- --arch=x86 --cpu=i686 --enable-runtime-cpudetect --sysroot=/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/sysroot --enable-pic --enable-libx264 --enable-libass --enable-libfreetype --enable-libfribidi --enable-libmp3lame --enable-fontconfig --enable-pthreads --disable-debug --disable-ffserver --enable-version3 --enable-hardcoded-tables --disable-ffplay --disable-ffprobe --enable-gpl --enable-yasm --disable-doc --disable-shared --enable-static --pkg-config=/home/vagrant/SourceCode/ffmpeg-android/ffmpeg-pkg-config --prefix=/home/vagrant/SourceCode/ffmpeg-android/build/x86 --extra-cflags='-I/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/include -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=2 -fno-strict-overflow -fstack-protector-all -march=i686' --extra-ldflags='-L/home/vagrant/SourceCode/ffmpeg-android/toolchain-android/lib -Wl,-z,relro -Wl,-z,now -pie' --extra-libs='-lpng -lexpat -lm' --extra-cxxflags=
           libavutil      55. 17.103 / 55. 17.103
           libavcodec     57. 24.102 / 57. 24.102
           libavformat    57. 25.100 / 57. 25.100
           libavdevice    57.  0.101 / 57.  0.101
           libavfilter     6. 31.100 /  6. 31.100
           libswscale      4.  0.100 /  4.  0.100
           libswresample   2.  0.101 /  2.  0.101
           libpostproc    54.  0.100 / 54.  0.100
           [udp @ 0x4203b040] 'circular_buffer_size' option was set but it is not supported on this build (pthread support is required)
           [udp @ 0x4203c040] 'circular_buffer_size' option was set but it is not supported on this build (pthread support is required)
           Input #0, rtsp, from 'rtsp://81.109.95.91:3000/stream':
           Metadata:
           title           : Session streamed with GStreamer
           comment         : rtsp-server
           Duration: N/A, start: 0.080000, bitrate: N/A
           Stream #0:0: Video: h264 (Constrained Baseline), yuv420p, 720x576, 25 fps, 25 tbr, 90k tbn, 180k tbc
           [libx264 @ 0x420a54c0] using cpu capabilities: none!
           [libx264 @ 0x420a54c0] profile High, level 3.0
           [libx264 @ 0x420a54c0] 264 - core 148 - H.264/MPEG-4 AVC codec - Copyleft 2003-2015 - 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, matroska, to '/storage/emulated/0/recording15072016-031605.mkv':
           Metadata:
           title           : Session streamed with GStreamer
           comment         : rtsp-server
           encoder         : Lavf57.25.100
           Stream #0:0: Video: h264 (libx264) (H264 / 0x34363248), yuv420p, 720x576, q=-1--1, 25 fps, 1k tbn, 25 tbc
           Metadata:
           encoder         : Lavc57.24.102 libx264
           Side data:
           unknown side data type 10 (24 bytes)
           Stream mapping:
           Stream #0:0 -> #0:0 (h264 (native) -> h264 (libx264))
           Press [q] to stop, [?] for help
           frame=   23 fps=0.0 q=0.0 size=       0kB time=00:00:00.00 bitrate=N/A speed=   0x
           [rtsp @ 0x420391c0] max delay reached. need to consume packet
           [NULL @ 0x4203ba00] RTP: missed 29 packets
           [h264 @ 0x45afe200] concealing 104 DC, 104 AC, 104 MV errors in P frame
           frame=   42 fps= 41 q=0.0 size=       0kB time=00:00:00.00 bitrate=N/A speed=   0x
           frame=   47 fps= 17 q=0.0 size=       0kB time=00:00:00.00 bitrate=N/A speed=   0x
           frame=   52 fps= 14 q=28.0 size=      36kB time=00:00:00.24 bitrate=1231.4kbits/s speed=0.0655x
           frame=   55 fps= 12 q=28.0 size=      46kB time=00:00:00.36 bitrate=1036.1kbits/s speed=0.0783x
           [rtsp @ 0x420391c0] max delay reached. need to con

    How to save rtsp stream without packet loss with good quality ? Any help will be appreciated.

  • ffmpeg concatenation after using drawtext filter

    12 août 2016, par Sven Hoskens

    I’m fairly new to ffmpeg, but after a few days of searching on this issue, I’ve completely hit a brick wall. Any help would be appreciated.

    My use case : Our client wants to upload videos for multiple regions. Each video will be the same format, 1920x1080, mp4. For each region, they want to add a different image at the end of the video, for a few seconds. This image contains their logo, some additional info, and a variable code. They will enter this code alongside the uploaded video. The image stays the same, so is already present on the server.
    So basically, I have an input video, a video of an image, and a small code. I need to add this code to the video of the image (in a predefined position), and then I need to add the resulting video to the end of the input video. Once that is complete, I just need to output the video in 1920x1080 and in 1024x576.

    I have tried several things, but the concatenation step always fails with the manipulated video’s.

    Attempt 1

    In my first attempt, I used ffmpeg to create a video from an image, and add the text in the designated area.

    ffmpeg -y -f lavfi -i image.png -r 30 -t 10 -pix_fmt yuv420p -map 0:v -vf drawtext="fontfile=HelveticaNeue.dfont: text='GLNS/TEST/1234b': fontcolor=black: fontsize=20: box=1: boxcolor=white: boxborderw=7: x=179: y=805" imageVideo.mp4

    This command creates a .mp4 video of the correct size, with a duration of 10 seconds, and adds the text ’GLNS/TEST/1234b’ in the correct location.

    Next, I use the following command to concatenate the two videos. Both have the same resolution and codec.

    ffmpeg -f concat -safe 0 -i config.txt -vf scale=1920:1080 outputHD.mp4 -vf scale=1024:576 outputSD.mp4

    config.txt contains following :

    file my_input_file.mp4
    file ImageVideo.mp4

    This concatenation works with regular videos. However, when I use it with ImageVideo.mp4 (the one created by the first command) I get this error log :

    [mov,mp4,m4a,3gp,3g2,mj2 @ 0x7f86dc924600] Auto-inserting h264_mp4toannexb bitstream filtereed=0.509x    
    [aac @ 0x7f86dc019e00] Number of bands (31) exceeds limit (5).
    Error while decoding stream #0:1: Invalid data found when processing input
    [aac @ 0x7f86dc019e00] Number of bands (27) exceeds limit (8).
    Error while decoding stream #0:1: Invalid data found when processing input
    [h264 @ 0x7f86dd857200] Error splitting the input into NAL units.
    [h264 @ 0x7f86dd829400] Invalid NAL unit size.
    [h264 @ 0x7f86dd829400] Error splitting the input into NAL units.
    [aac @ 0x7f86dc019e00] Number of bands (10) exceeds limit (1).
    Error while decoding stream #0:1: Invalid data found when processing input
    [h264 @ 0x7f86dd816800] Invalid NAL unit size.
    [h264 @ 0x7f86dd816800] Error splitting the input into NAL units.
    [aac @ 0x7f86dc019e00] Number of bands (24) exceeds limit (1).
    Error while decoding stream #0:1: Invalid data found when processing input

    #this goes on for a few hundred lines

    The resulting output is identical to the input video, but does not contain the desired image video at the end.

    Attempt 2

    Since the above attempt didn’t work, I tried concatenating a video I let our designer make of the image with Adobe After Effects. This video was also saved as a .mp4 with the H264 codec. If I concatenate the input video and this one, I get a correct result. However, as soon as I add the code in the designated area with this command :

    ffmpeg -i new_image_video.mp4 -vf drawtext="fontfile=HelveticaNeue.dfont: text='GLNS/TEST/1234b': fontcolor=black: fontsize=20: box=1: boxcolor=white: boxborderw=7: x=179: y=805" -c:v libx264 imageVideo.mp4

    I get this error :

    [mov,mp4,m4a,3gp,3g2,mj2 @ 0x7ff94c800000] Auto-inserting h264_mp4toannexb bitstream filter97x    
    [h264 @ 0x7ff94b053800] top block unavailable for requested intra mode -1
    [h264 @ 0x7ff94b053800] error while decoding MB 0 0, bytestream 49526
    [h264 @ 0x7ff94b053e00] number of reference frames (1+3) exceeds max (3; probably corrupt input), discarding one
    [h264 @ 0x7ff94b053e00] chroma_log2_weight_denom 28 is out of range
    [h264 @ 0x7ff94b053e00] illegal long ref in memory management control operation 2
    [h264 @ 0x7ff94b053e00] cabac_init_idc 32 overflow
    [h264 @ 0x7ff94b053e00] decode_slice_header error
    [h264 @ 0x7ff94b053e00] no frame!
    [h264 @ 0x7ff94b053800] concealing 8160 DC, 8160 AC, 8160 MV errors in I frame
    [h264 @ 0x7ff94b072a00] reference overflow 22 > 15 or 0 > 15
    [h264 @ 0x7ff94b072a00] decode_slice_header error
    [h264 @ 0x7ff94b072a00] no frame!
    [h264 @ 0x7ff94b01a400] illegal modification_of_pic_nums_idc 20
    [h264 @ 0x7ff94b01a400] decode_slice_header error
    [h264 @ 0x7ff94b01a400] no frame!
    [h264 @ 0x7ff94b01aa00] illegal modification_of_pic_nums_idc 20
    [h264 @ 0x7ff94b01aa00] decode_slice_header error
    [h264 @ 0x7ff94b01aa00] no frame!
    Error while decoding stream #0:0: Invalid data found when processing input
    [h264 @ 0x7ff94b053800] deblocking_filter_idc 8 out of range
    [h264 @ 0x7ff94b053800] decode_slice_header error
    [h264 @ 0x7ff94b053800] no frame!
    Error while decoding stream #0:0: Invalid data found when processing input
    [h264 @ 0x7ff94b053e00] illegal memory management control operation 8
    [h264 @ 0x7ff94b053e00] co located POCs unavailable
    [h264 @ 0x7ff94b053e00] error while decoding MB 2 0, bytestream -35
    [h264 @ 0x7ff94b053e00] concealing 8160 DC, 8160 AC, 8160 MV errors in B frame
    [h264 @ 0x7ff94b072a00] number of reference frames (1+3) exceeds max (3; probably corrupt input), discarding one

    # this goes on for a while...

    [h264 @ 0x7ff94b01a400] concealing 4962 DC, 4962 AC, 4962 MV errors in B frame
    Error while decoding stream #0:0: Invalid data found when processing input
    frame= 2553 fps= 17 q=-1.0 Lsize=   26995kB time=00:01:42.16 bitrate=2164.6kbits/s dup=0 drop=60 speed=0.697x    
    video:25258kB audio:1661kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.285236%
    [libx264 @ 0x7ff94b810400] frame I:35    Avg QP:17.45  size: 55070
    [libx264 @ 0x7ff94b810400] frame P:711   Avg QP:19.73  size: 18712
    [libx264 @ 0x7ff94b810400] frame B:1807  Avg QP:21.53  size:  5884
    [libx264 @ 0x7ff94b810400] consecutive B-frames:  3.4%  5.0%  4.9% 86.6%
    [libx264 @ 0x7ff94b810400] mb I  I16..4: 38.2% 49.3% 12.5%
    [libx264 @ 0x7ff94b810400] mb P  I16..4: 12.4% 14.0%  1.0%  P16..4: 29.6%  4.8%  1.9%  0.0%  0.0%    skip:36.2%
    [libx264 @ 0x7ff94b810400] mb B  I16..4:  1.5%  1.2%  0.1%  B16..8: 27.3%  1.6%  0.1%  direct: 1.8%  skip:66.4%  L0:45.8% L1:51.4% BI: 2.8%
    [libx264 @ 0x7ff94b810400] 8x8 transform intra:49.5% inter:85.4%
    [libx264 @ 0x7ff94b810400] coded y,uvDC,uvAC intra: 21.2% 22.3% 2.5% inter: 4.6% 7.0% 0.0%
    [libx264 @ 0x7ff94b810400] i16 v,h,dc,p: 23% 26% 10% 41%
    [libx264 @ 0x7ff94b810400] i8 v,h,dc,ddl,ddr,vr,hd,vl,hu: 31% 19% 35%  3%  3%  3%  3%  3%  2%
    [libx264 @ 0x7ff94b810400] i4 v,h,dc,ddl,ddr,vr,hd,vl,hu: 31% 20% 16%  5%  7%  6%  5%  5%  4%
    [libx264 @ 0x7ff94b810400] i8c dc,h,v,p: 67% 16% 15%  2%
    [libx264 @ 0x7ff94b810400] Weighted P-Frames: Y:7.3% UV:4.2%
    [libx264 @ 0x7ff94b810400] ref P L0: 66.3%  8.7% 17.9%  7.0%  0.1%
    [libx264 @ 0x7ff94b810400] ref B L0: 88.2% 10.1%  1.7%
    [libx264 @ 0x7ff94b810400] ref B L1: 94.9%  5.1%
    [libx264 @ 0x7ff94b810400] kb/s:2026.12
    [aac @ 0x7ff94b072400] Qavg: 635.626

    The resulting output is identical to the input video, but does not contain the desired image video at the end.

    One thing I have noticed : When I inspect the video files on mac (Get info) they always contain these lines at ’More info’ :

    Dimensions: 1920 x 1080
    Codecs: H.264, AAC
    Color profile: HD(1-1-1)
    Duration: 01:42
    Audio channels: 2
    Last opened: Today 11:02

    However, the video’s which pass through the drawtext filter have this :

    Dimensions: 1920 x 1080
    Codecs: AAC, H.264
    Duration: 00:10
    Audio channels: 2
    Last opened: Today 11:07

    As you can see, there is no color profile entry, and the codecs have switched places. I assume this is related to my issue, but I can’t seem to find a fix for it.

    PS : The application will run in a php environment (Symfony). I noticed the concat command wasn’t available in the Symfony bundle for ffmpeg, so I’m using the regular terminal commands. I’ll execute these using php.

    EDIT
    Attempt 3

    On advise of a coworker, I tried converting the video to .avi and reconverting to .mp4, in the hopes this would lose any corrupted or extra info included by the drawtext filter. This spits out a completely different error.

    [mov,mp4,m4a,3gp,3g2,mj2 @ 0x7f812413da00] Auto-inserting h264_mp4toannexb bitstream filtereed=0.516x    
    [concat @ 0x7f8124009a00] DTS 1569260 < 2551000 out of order
    [h264 @ 0x7f8124846800] left block unavailable for requested intra4x4 mode -1
    [h264 @ 0x7f8124846800] error while decoding MB 0 0, bytestream 47919
    [h264 @ 0x7f8124846800] concealing 8160 DC, 8160 AC, 8160 MV errors in I frame
    [aac @ 0x7f8125809a00] Queue input is backward in time
    [aac @ 0x7f8125815a00] Queue input is backward in time
    [h264 @ 0x7f8124846e00] number of reference frames (1+3) exceeds max (3; probably corrupt input), discarding one
    [h264 @ 0x7f8124846e00] chroma_log2_weight_denom 26 is out of range
    [h264 @ 0x7f8124846e00] deblocking_filter_idc 32 out of range
    [h264 @ 0x7f8124846e00] decode_slice_header error
    [h264 @ 0x7f8124846e00] no frame!
    [mp4 @ 0x7f8124802200] Non-monotonous DTS in output stream 0:1; previous: 4902912, current: 4505491; changing to 4902913. This may result in incorrect timestamps in the output file.
    [mp4 @ 0x7f8125813000] Non-monotonous DTS in output stream 1:1; previous: 4902912, current: 4505491; changing to 4902913. This may result in incorrect timestamps in the output file.
    [h264 @ 0x7f8124803400] reference overflow 20 > 15 or 0 > 15
    [h264 @ 0x7f8124803400] decode_slice_header error
    [h264 @ 0x7f8124803400] no frame!
    [mp4 @ 0x7f8124802200] Non-monotonous DTS in output stream 0:1; previous: 4902913, current: 4506515; changing to 4902914. This may result in incorrect timestamps in the output file.
    [mp4 @ 0x7f8125813000] Non-monotonous DTS in output stream 1:1; previous: 4902913, current: 4506515; changing to 4902914. This may result in incorrect timestamps in the output file.
    [mp4 @ 0x7f8124802200] Non-monotonous DTS in output stream 0:1; previous: 4902914, current: 4507539; changing to 4902915. This may result in incorrect timestamps in the output file.
    [mp4 @ 0x7f8125813000] Non-monotonous DTS in output stream 1:1; previous: 4902914, current: 4507539; changing to 4902915. This may result in incorrect timestamps in the output file.

    # Again, this continues for quite a while.