[FFmpeg-trac] #2938(undetermined:new): Incorrect start time and duration when transcoding audio-only (-vn) from A/V files.

FFmpeg trac at avcodec.org
Fri Sep 6 00:10:05 CEST 2013


#2938: Incorrect start time and duration when transcoding audio-only (-vn) from
A/V files.
-------------------------------------+-------------------------------------
             Reporter:  rlabonte     |                    Owner:
                 Type:  defect       |                   Status:  new
             Priority:  normal       |                Component:
              Version:  git-master   |  undetermined
             Keywords:               |               Resolution:
             Blocking:               |               Blocked By:
Analyzed by developer:  0            |  Reproduced by developer:  0
-------------------------------------+-------------------------------------

Comment (by rlabonte):

 Replying to [comment:1 cehoyos]:
 > Replying to [ticket:2938 rlabonte]:
 > > Muxing to matroska or raw AAC results in a 0.00 start time, but the
 duration is still off by 40ms.
 >
 > Does this mean audio gets significantly longer (or shorter?) if you
 encode several times?

 I ran the same command as above but muxed to an MKV container.

 FFprobe output from MKV output of the same command as before:

 {{{
 % ffprobe offset.mkv -show_streams -show_format
 ffprobe version N-56052-g59b9ecc Copyright (c) 2007-2013 the FFmpeg
 developers
   built on Sep  5 2013 14:16:47 with gcc 4.4.3 (Ubuntu 4.4.3-4ubuntu5.1)
   configuration: --enable-nonfree --enable-gpl --enable-version3 --enable-
 libvpx --enable-libtheora --enable-libvorbis --enable-libfaac --enable-
 libfdk_aac --enable-libx264 --enable-libfreetype
   libavutil      52. 43.100 / 52. 43.100
   libavcodec     55. 31.101 / 55. 31.101
   libavformat    55. 16.101 / 55. 16.101
   libavdevice    55.  3.100 / 55.  3.100
   libavfilter     3. 83.102 /  3. 83.102
   libswscale      2.  5.100 /  2.  5.100
   libswresample   0. 17.103 /  0. 17.103
   libpostproc    52.  3.100 / 52.  3.100
 Input #0, matroska,webm, from 'offset.mkv':
   Metadata:
     MAJOR_BRAND     : qt
     MINOR_VERSION   : 537199360
     COMPATIBLE_BRANDS: qt
     TIMECODE        : 00:00:00:00
     ENCODER         : Lavf55.16.101
   Duration: 00:09:56.50, start: 0.000000, bitrate: 130 kb/s
     Stream #0:0(eng): Audio: aac, 48000 Hz, 5.1, fltp (default)
     Metadata:
       CREATION_TIME   : 2008-05-27 18:32:32
       LANGUAGE        : eng
       HANDLER_NAME    : Apple Alias Data Handler
 [STREAM]
 index=0
 codec_name=aac
 codec_long_name=AAC (Advanced Audio Coding)
 profile=unknown
 codec_type=audio
 codec_time_base=1/48000
 codec_tag_string=[0][0][0][0]
 codec_tag=0x0000
 sample_fmt=fltp
 sample_rate=48000
 channels=6
 bits_per_sample=0
 id=N/A
 r_frame_rate=0/0
 avg_frame_rate=0/0
 time_base=1/1000
 start_pts=0
 start_time=0.000000
 duration_ts=N/A
 duration=N/A
 bit_rate=N/A
 nb_frames=N/A
 nb_read_frames=N/A
 nb_read_packets=N/A
 DISPOSITION:default=1
 DISPOSITION:dub=0
 DISPOSITION:original=0
 DISPOSITION:comment=0
 DISPOSITION:lyrics=0
 DISPOSITION:karaoke=0
 DISPOSITION:forced=0
 DISPOSITION:hearing_impaired=0
 DISPOSITION:visual_impaired=0
 DISPOSITION:clean_effects=0
 DISPOSITION:attached_pic=0
 TAG:CREATION_TIME=2008-05-27 18:32:32
 TAG:LANGUAGE=eng
 TAG:HANDLER_NAME=Apple Alias Data Handler
 [/STREAM]
 [FORMAT]
 filename=offset.mkv
 nb_streams=1
 nb_programs=0
 format_name=matroska,webm
 format_long_name=Matroska / WebM
 start_time=0.000000
 duration=596.501000
 size=9757210
 bit_rate=130859
 probe_score=100
 TAG:MAJOR_BRAND=qt
 TAG:MINOR_VERSION=537199360
 TAG:COMPATIBLE_BRANDS=qt
 TAG:TIMECODE=00:00:00:00
 TAG:ENCODER=Lavf55.16.101
 [/FORMAT]
 }}}

 I previously failed to mention, -c:a copy is unaffected by this bug.  I
 did a -c:a copy of the resulting mkv version to a new mov container and
 got this:

 {{{
 % ffprobe offset_from_mkv.mov  -show_streams -show_format
 ffprobe version N-56052-g59b9ecc Copyright (c) 2007-2013 the FFmpeg
 developers
   built on Sep  5 2013 14:16:47 with gcc 4.4.3 (Ubuntu 4.4.3-4ubuntu5.1)
   configuration: --enable-nonfree --enable-gpl --enable-version3 --enable-
 libvpx --enable-libtheora --enable-libvorbis --enable-libfaac --enable-
 libfdk_aac --enable-libx264 --enable-libfreetype
   libavutil      52. 43.100 / 52. 43.100
   libavcodec     55. 31.101 / 55. 31.101
   libavformat    55. 16.101 / 55. 16.101
   libavdevice    55.  3.100 / 55.  3.100
   libavfilter     3. 83.102 /  3. 83.102
   libswscale      2.  5.100 /  2.  5.100
   libswresample   0. 17.103 /  0. 17.103
   libpostproc    52.  3.100 / 52.  3.100
 Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'offset_from_mkv.mov':
   Metadata:
     major_brand     : qt
     minor_version   : 512
     compatible_brands: qt
     encoder         : Lavf55.16.101
   Duration: 00:09:56.50, start: 0.000000, bitrate: 129 kb/s
     Stream #0:0(eng): Audio: aac (mp4a / 0x6134706D), 48000 Hz, 5.1, fltp,
 128 kb/s (default)
     Metadata:
       handler_name    : DataHandler
 [STREAM]
 index=0
 codec_name=aac
 codec_long_name=AAC (Advanced Audio Coding)
 profile=unknown
 codec_type=audio
 codec_time_base=1/48000
 codec_tag_string=mp4a
 codec_tag=0x6134706d
 sample_fmt=fltp
 sample_rate=48000
 channels=6
 bits_per_sample=0
 id=N/A
 r_frame_rate=0/0
 avg_frame_rate=0/0
 time_base=1/48000
 start_pts=0
 start_time=0.000000
 duration_ts=28632040
 duration=596.500833
 bit_rate=128196
 nb_frames=27961
 nb_read_frames=N/A
 nb_read_packets=N/A
 DISPOSITION:default=1
 DISPOSITION:dub=0
 DISPOSITION:original=0
 DISPOSITION:comment=0
 DISPOSITION:lyrics=0
 DISPOSITION:karaoke=0
 DISPOSITION:forced=0
 DISPOSITION:hearing_impaired=0
 DISPOSITION:visual_impaired=0
 DISPOSITION:clean_effects=0
 DISPOSITION:attached_pic=0
 TAG:language=eng
 TAG:handler_name=DataHandler
 [/STREAM]
 [FORMAT]
 filename=offset_from_mkv.mov
 nb_streams=1
 nb_programs=0
 format_name=mov,mp4,m4a,3gp,3g2,mj2
 format_long_name=QuickTime / MOV
 start_time=0.000000
 duration=596.501000
 size=9671451
 bit_rate=129709
 probe_score=100
 TAG:major_brand=qt
 TAG:minor_version=512
 TAG:compatible_brands=qt
 TAG:encoder=Lavf55.16.101
 [/FORMAT]
 }}}

-- 
Ticket URL: <https://ffmpeg.org/trac/ffmpeg/ticket/2938#comment:2>
FFmpeg <http://ffmpeg.org>
FFmpeg issue tracker


More information about the FFmpeg-trac mailing list