[FFmpeg-trac] #4233(ffmpeg:new): FFmpeg adds 3 frames on reencode with timecode burnin

FFmpeg trac at avcodec.org
Wed Jan 7 19:01:05 CET 2015


#4233: FFmpeg adds 3 frames on reencode with timecode burnin
--------------------------------+--------------------------------------
             Reporter:  steved  |                     Type:  defect
               Status:  new     |                 Priority:  normal
            Component:  ffmpeg  |                  Version:  git-master
             Keywords:          |               Blocked By:
             Blocking:          |  Reproduced by developer:  0
Analyzed by developer:  0       |
--------------------------------+--------------------------------------
 Hello,

 I have a mp4 source file and reencode it to mp4 with a different
 resolution and a burned in timecode. Afterwards the new file has 3
 additional frames which leads to a miss matching timecode.

 How to reproduce:
 {{{
 % ffmpeg -t 15.182  -i "163304323.mp4" -r 23.976 -pix_fmt yuv420p -aspect
 640/360 -vf
 "scale='ceil(iw*sar/2)*2':'ceil(ih/2)*2',pad='max(iw,ih*(640/360))':'ow/(640/360
 )':'(ow-iw)/2':'(oh-ih)/2':black,scale=640:360" -c:v libx264 -b:v 1500k
 -c:a libfdk_aac -b:a 128k -g 50 -keyint_min 50 -movflags faststart -y
 "out.mp4"
 }}}

 FFmpeg version:

 {{{
 % ffmpeg version N-68933-gad465e7 Copyright (c) 2000-2015 the FFmpeg
 developers
   built on Jan  7 2015 15:54:46 with gcc 4.4.7 (GCC) 20120313 (Red Hat
 4.4.7-11)
   configuration: --prefix=/opt/sb4/stage --extra-
 cflags=-I/opt/sb4/stage/include --extra-ldflags=-L/opt/sb4/stage/lib
 --extra-libs=-ldl --enable-gpl --enable-nonfree --enable-libfaac --enable-
 libx264 --enable-libfreetype --enable-pthreads --enable-libvpx --enable-
 libvorbis --enable-libfdk-aac
   libavutil      54. 16.100 / 54. 16.100
   libavcodec     56. 20.100 / 56. 20.100
   libavformat    56. 18.100 / 56. 18.100
   libavdevice    56.  3.100 / 56.  3.100
   libavfilter     5.  6.100 /  5.  6.100
   libswscale      3.  1.101 /  3.  1.101
   libswresample   1.  1.100 /  1.  1.100
   libpostproc    53.  3.100 / 53.  3.100
 }}}

 Information about the input file:

 {{{
 % ffprobe input.mp4
 ffprobe version N-68933-gad465e7 Copyright (c) 2007-2015 the FFmpeg
 developers
   built on Jan  7 2015 15:54:46 with gcc 4.4.7 (GCC) 20120313 (Red Hat
 4.4.7-11)
   configuration: --prefix=/opt/sb4/stage --extra-
 cflags=-I/opt/sb4/stage/include --extra-ldflags=-L/opt/sb4/stage/lib
 --extra-libs=-ldl --enable-gpl --enable-nonfree --enable-libfaac --enable-
 libx264 --enable-libfreetype --enable-pthreads --enable-libvpx --enable-
 libvorbis --enable-libfdk-aac
   libavutil      54. 16.100 / 54. 16.100
   libavcodec     56. 20.100 / 56. 20.100
   libavformat    56. 18.100 / 56. 18.100
   libavdevice    56.  3.100 / 56.  3.100
   libavfilter     5.  6.100 /  5.  6.100
   libswscale      3.  1.101 /  3.  1.101
   libswresample   1.  1.100 /  1.  1.100
   libpostproc    53.  3.100 / 53.  3.100
 Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '163304323.mp4':
   Metadata:
     major_brand     : mp42
     minor_version   : 0
     compatible_brands: mp42mp41isomavc1
     creation_time   : 2013-05-08 19:56:14
   Duration: 00:00:15.18, start: 0.042667, bitrate: 2418 kb/s
     Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p,
 1280x720 [SAR 1:1 DAR 16:9], 2256 kb/s, 23.98 fps, 23.98 tbr, 24k tbn,
 47.95 tbc (default)
     Metadata:
       creation_time   : 2013-05-08 19:56:14
       handler_name    : L-SMASH Video Handler
       encoder         : AVC Coding
     Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz,
 stereo, fltp, 157 kb/s (default)
     Metadata:
       creation_time   : 2013-05-08 19:56:14
       handler_name    : L-SMASH Audio Handler
 }}}

 Information about the output file:

 {{{
 % ffprobe out.mp4
 ffprobe version N-68933-gad465e7 Copyright (c) 2007-2015 the FFmpeg
 developers
   built on Jan  7 2015 15:54:46 with gcc 4.4.7 (GCC) 20120313 (Red Hat
 4.4.7-11)
   configuration: --prefix=/opt/sb4/stage --extra-
 cflags=-I/opt/sb4/stage/include --extra-ldflags=-L/opt/sb4/stage/lib
 --extra-libs=-ldl --enable-gpl --enable-nonfree --enable-libfaac --enable-
 libx264 --enable-libfreetype --enable-pthreads --enable-libvpx --enable-
 libvorbis --enable-libfdk-aac
   libavutil      54. 16.100 / 54. 16.100
   libavcodec     56. 20.100 / 56. 20.100
   libavformat    56. 18.100 / 56. 18.100
   libavdevice    56.  3.100 / 56.  3.100
   libavfilter     5.  6.100 /  5.  6.100
   libswscale      3.  1.101 /  3.  1.101
   libswresample   1.  1.100 /  1.  1.100
   libpostproc    53.  3.100 / 53.  3.100
 Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '163304323.mp4.mp4':
   Metadata:
     major_brand     : isom
     minor_version   : 512
     compatible_brands: isomiso2avc1mp41
     encoder         : Lavf56.18.100
   Duration: 00:00:15.28, start: 0.042667, bitrate: 1609 kb/s
     Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p,
 640x360 [SAR 1:1 DAR 16:9], 1476 kb/s, 23.98 fps, 23.98 tbr, 11988 tbn,
 47.95 tbc (default)
     Metadata:
       handler_name    : VideoHandler
     Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz,
 stereo, fltp, 128 kb/s (default)
     Metadata:
       handler_name    : SoundHandler
 }}}

--
Ticket URL: <https://trac.ffmpeg.org/ticket/4233>
FFmpeg <https://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list