Opened 9 months ago

#6927 new defect

FFMPEG version 3.4 gives wrong timestamps unless running with -advanced_editlist 0

Reported by: EduardSinelnikov81 Owned by:
Priority: important Component: undetermined
Version: 3.4 Keywords:
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Running on this command
ffmpeg -loglevel error -y -timelimit 2880 -i ~/sample.mp3 -loop 1 -i ~/couple.jpg -sws_flags lanczos -filter_complex "[0:a]anull[a1] ; [1:v]null[v1] ; [v1]null[v2] ; [a1]anull[a2] " -map '[v2]' -map '[a2]' -codec:v libx264 -profile:v baseline -flags +global_header -movflags +faststart -codec:a libfdk_aac -bsf:a aac_adtstoasc -pix_fmt yuv420p -crf 27 -threads 4 ~/movieformAudio.mp4

Produces a file of length 1:27:90

ffprobe version n3.4 Copyright (c) 2007-2017 the FFmpeg developers

built with gcc 5.4.0 (Ubuntu 5.4.0-6ubuntu1~16.04.5) 20160609
configuration: --extra-libs=-ldl --enable-gpl --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-nonfree --enable-avresample --disable-debug --enable-gpl --enable-version3 --enable-avisynth --enable-libwebp --enable-libopenjpeg --enable-libvidstab --disable-doc --cpu=host --disable-demuxer=hls --disable-protocols --enable-protocol=file --enable-protocol=pipe --disable-protocol=http --enable-demuxer=rtp --enable-muxer=hls
libavutil 55. 78.100 / 55. 78.100
libavcodec 57.107.100 / 57.107.100
libavformat 57. 83.100 / 57. 83.100
libavdevice 57. 10.100 / 57. 10.100
libavfilter 6.107.100 / 6.107.100
libavresample 3. 7. 0 / 3. 7. 0
libswscale 4. 8.100 / 4. 8.100
libswresample 2. 9.100 / 2. 9.100
libpostproc 54. 7.100 / 54. 7.100

Input #0, mov,mp4,m4a,3gp,3g2,mj2, from '/home/ubuntu/movieformAudio.mp4':

Metadata:

major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
title : Tail Toddle
artist : Tony Cuffe
album : Sae Will We Yet
date : 2003
encoder : Lavf57.83.100
comment : sample of full track
genre : Celtic
copyright : The Windbags
track : 1

Duration: 00:01:27.96, start: 0.000000, bitrate: 56 kb/s

Stream #0:0(und): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p, 400x300 [SAR 1:1 DAR 4:3], 22 kb/s, 25 fps, 25 tbr, 12800 tbn, 50 tbc (default)
Metadata:

handler_name : VideoHandler?

Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 11025 Hz, stereo, fltp, 32 kb/s (default)
Metadata:

handler_name : SoundHandler?

While the input file 'sample.mp3' is of the lenght 1:27:80

ubuntu@ubuntu-xenial:~/FFMPEG_COMPILE/FFmpeg_3_4$ ./ffprobe ~/sample.mp3
ffprobe version n3.4 Copyright (c) 2007-2017 the FFmpeg developers

built with gcc 5.4.0 (Ubuntu 5.4.0-6ubuntu1~16.04.5) 20160609
configuration: --extra-libs=-ldl --enable-gpl --enable-libass --enable-libfdk-aac --enable-libfreetype --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-nonfree --enable-avresample --disable-debug --enable-gpl --enable-version3 --enable-avisynth --enable-libwebp --enable-libopenjpeg --enable-libvidstab --disable-doc --cpu=host --disable-demuxer=hls --disable-protocols --enable-protocol=file --enable-protocol=pipe --disable-protocol=http --enable-demuxer=rtp --enable-muxer=hls
libavutil 55. 78.100 / 55. 78.100
libavcodec 57.107.100 / 57.107.100
libavformat 57. 83.100 / 57. 83.100
libavdevice 57. 10.100 / 57. 10.100
libavfilter 6.107.100 / 6.107.100
libavresample 3. 7. 0 / 3. 7. 0
libswscale 4. 8.100 / 4. 8.100
libswresample 2. 9.100 / 2. 9.100
libpostproc 54. 7.100 / 54. 7.100

[mp3 @ 0x33e5f00] Estimating duration from bitrate, this may be inaccurate
Input #0, mp3, from '/home/ubuntu/sample.mp3':

Metadata:

track : 1
copyright : The Windbags
TOPE : The Windbags
comment : sample of full track
genre : Celtic
album : Sae Will We Yet
artist : Tony Cuffe
title : Tail Toddle
date : 2003

Duration: 00:01:27.80, start: 0.000000, bitrate: 32 kb/s

Stream #0:0: Audio: mp3, 11025 Hz, stereo, s16p, 32 kb/s

This is a regretion since on 3.1.4 was no such problem.
This can be fixed by using -advanced_editlist 0 but this fails if used on non-mov files, such as mp3.

ffmpeg version n3_4 built on linux machine

Attachments (2)

sample.mp3 (344.0 KB) - added by EduardSinelnikov81 9 months ago.
sample audio file
couple.jpg (202.1 KB) - added by EduardSinelnikov81 9 months ago.
couple image

Download all attachments as: .zip

Change History (2)

Changed 9 months ago by EduardSinelnikov81

sample audio file

Changed 9 months ago by EduardSinelnikov81

couple image

Note: See TracTickets for help on using tickets.