[FFmpeg-trac] #9524(ffmpeg:new): concat of videos with different frame rates ends with endless loop of frame duplication

FFmpeg trac at avcodec.org
Mon Nov 22 17:51:49 EET 2021


#9524: concat of videos with different frame rates ends with endless loop of frame
duplication
-----------------------------------+----------------------------------
             Reporter:  rotemc     |                    Owner:  (none)
                 Type:  defect     |                   Status:  new
             Priority:  normal     |                Component:  ffmpeg
              Version:  4.4.1      |               Resolution:
             Keywords:  framerate  |               Blocked By:
             Blocking:             |  Reproduced by developer:  1
Analyzed by developer:  1          |
-----------------------------------+----------------------------------
Changes (by rotemc):

 * keywords:   => framerate


Old description:

> Summary of the bug:
> It seems that concatenation command for videos with different frame rates
> gets into endless loop of duplicating frames.
> Debug tracing for example:
> cur_dts is invalid st:0 (0) [init:1 i_done:0 finish:0] (this is harmless
> if it occurs once at the start per stream)
>     Last message repeated 2 times
> *** 33331 dup!
> More than 1000 frames duplicated
>
> It works fine in 4.2
>
> How to reproduce:
> {{{
> % /opt/ffmpeg-4.4.1/bin/ffmpeg -loglevel debug -y -timelimit 2880 -i
> spec/videos/first.mp4 -i spec/videos/second.mp4 -sws_flags lanczos
> -filter_complex "[0:v]null[j1] ; [0:a]anull[a1] ; [1:v]null[j2] ;
> [1:a]anull[a2] ; [j1][a1][j2][a2]concat=n=2:a=1:v=1[v9][a3]" -codec:v
> libx264 -map '[v9]' -map '[a3]' -start_at_zero public/test.mp4
> ffmpeg version 4.4.1
> built on Ubuntu/mac
> }}}
> Patches should be submitted to the ffmpeg-devel mailing list and not this
> bug tracker.

New description:

 Summary of the bug:
 -------------------
 It seems that concatenation command for videos with different frame rates
 gets into endless loop of duplicating frames.

 Debug tracing for example:
 --------------------------
 cur_dts is invalid st:0 (0) [init:1 i_done:0 finish:0] (this is harmless
 if it occurs once at the start per stream)
     Last message repeated 2 times
 *** 33331 dup!
 More than 1000 frames duplicated

 It works fine in 4.2

 How to reproduce:
 -----------------
 {{{
 % /opt/ffmpeg-4.4.1/bin/ffmpeg -loglevel debug -y -timelimit 2880 -i
 spec/videos/first.mp4 -i spec/videos/second.mp4 -sws_flags lanczos
 -filter_complex "[0:v]null[j1] ; [0:a]anull[a1] ; [1:v]null[j2] ;
 [1:a]anull[a2] ; [j1][a1][j2][a2]concat=n=2:a=1:v=1[v9][a3]" -codec:v
 libx264 -map '[v9]' -map '[a3]' -start_at_zero public/test.mp4
 ffmpeg version 4.4.1
 built on Ubuntu/mac
 }}}

--
-- 
Ticket URL: <https://trac.ffmpeg.org/ticket/9524#comment:1>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list