[FFmpeg-trac] #3339(undetermined:open): Remuxing m2ts to mkv, Can't write packet with unknown timestamp

FFmpeg trac at avcodec.org
Sun Feb 8 17:15:56 CET 2015


#3339: Remuxing m2ts to mkv,  Can't write packet with unknown timestamp
-------------------------------------+-------------------------------------
             Reporter:  Selur        |                    Owner:
                 Type:  defect       |                   Status:  open
             Priority:  important    |                Component:
              Version:  git-master   |  undetermined
             Keywords:               |               Resolution:
  av_interleaved_write_frame h264    |               Blocked By:
  regression                         |  Reproduced by developer:  1
             Blocking:               |
Analyzed by developer:  0            |
-------------------------------------+-------------------------------------

Comment (by pchristy):

 I'm also having this issue on a Slackware64-current install. Initially
 occurred with ffmpeg-2.5.3, but also with just-compiled snapshot (8th Feb
 2015). Adding "-fflags +genpts" makes no difference. Re-muxing the same
 file to mp4 works fine! Re-muxing that mp4 file to mkv also works fine!!!

 Source file came from Panasonic HDC-SD10 camcorder. I can provide sample
 if required.

 Here is the auto-generated log file:
 {{{
 ffmpeg started on 2015-02-08 at 15:29:52
 Report written to "ffmpeg-20150208-152952.log"
 Command line:
 ffmpeg -report -i helicopter.mts -f matroska -c copy helicopter.mkv
 ffmpeg version 2.5.git Copyright (c) 2000-2015 the FFmpeg developers
   built with gcc 4.8.4 (GCC)
   configuration: --prefix=/usr --libdir=/usr/lib64 --shlibdir=/usr/lib64
 --arch=x86_64 --enable-gpl --enable-shared --enable-postproc --enable-
 pthreads --enable-nonfree --enable-libmp3lame --enable-libtheora --enable-
 libvorbis --enable-libxvid --enable-libx264 --enable-avresample --enable-
 libfaac --enable-x11grab --enable-libgsm --enable-libdc1394 --disable-
 stripping --enable-avfilter --enable-libschroedinger --enable-libopencore-
 amrnb --enable-libopencore-amrwb --enable-version3 --enable-vaapi
   libavutil      54. 18.100 / 54. 18.100
   libavcodec     56. 21.102 / 56. 21.102
   libavformat    56. 19.100 / 56. 19.100
   libavdevice    56.  4.100 / 56.  4.100
   libavfilter     5.  9.103 /  5.  9.103
   libavresample   2.  1.  0 /  2.  1.  0
   libswscale      3.  1.101 /  3.  1.101
   libswresample   1.  1.100 /  1.  1.100
   libpostproc    53.  3.100 / 53.  3.100
 Splitting the commandline.
 Reading option '-report' ... matched as option 'report' (generate a
 report) with argument '1'.
 Reading option '-i' ... matched as input file with argument
 'helicopter.mts'.
 Reading option '-f' ... matched as option 'f' (force format) with argument
 'matroska'.
 Reading option '-c' ... matched as option 'c' (codec name) with argument
 'copy'.
 Reading option 'helicopter.mkv' ... matched as output file.
 Finished splitting the commandline.
 Parsing a group of options: global .
 Applying option report (generate a report) with argument 1.
 Successfully parsed a group of options.
 Parsing a group of options: input file helicopter.mts.
 Successfully parsed a group of options.
 Opening an input file: helicopter.mts.
 [mpegts @ 0x8f3dc0] Format mpegts probed with size=2048 and score=100
 [mpegts @ 0x8f3dc0] stream=0 stream_type=1b pid=1011 prog_reg_desc=HDMV
 [mpegts @ 0x8f3dc0] stream=1 stream_type=81 pid=1100 prog_reg_desc=HDMV
 [mpegts @ 0x8f3dc0] stream=2 stream_type=90 pid=1200 prog_reg_desc=HDMV
 [mpegts @ 0x8f3dc0] Before avformat_find_stream_info() pos: 0 bytes
 read:32768 seeks:0
 [mpegts @ 0x8f3dc0] parser not found for codec hdmv_pgs_subtitle, packets
 or times may be invalid.
 [mpegts @ 0x8f3dc0] parser not found for codec hdmv_pgs_subtitle, packets
 or times may be invalid.
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 2 with DTS
 69823, packet 3 with DTS 69823
 [h264 @ 0x8f7bc0] no picture
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 5 with DTS
 113023, packet 6 with DTS 113023
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 6 with DTS
 113023, packet 7 with DTS 113023
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 7 with DTS
 113023, packet 8 with DTS 113023
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 10 with DTS
 156223, packet 11 with DTS 156223
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 11 with DTS
 156223, packet 12 with DTS 156223
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 12 with DTS
 156223, packet 13 with DTS 156223
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 15 with DTS
 199423, packet 16 with DTS 199423
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 16 with DTS
 199423, packet 17 with DTS 199423
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 17 with DTS
 199423, packet 18 with DTS 199423
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 20 with DTS
 242623, packet 21 with DTS 242623
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 21 with DTS
 242623, packet 22 with DTS 242623
 [mpegts @ 0x8f3dc0] Non-increasing DTS in stream 2: packet 22 with DTS
 242623, packet 23 with DTS 242623
 [mpegts @ 0x8f3dc0] Probe buffer size limit of 5000000 bytes reached
 [mpegts @ 0x8f3dc0] PES packet size mismatch
 [mpegts @ 0x8f3dc0] After avformat_find_stream_info() pos: 0 bytes
 read:5607568 seeks:2 frames:210
 Input #0, mpegts, from 'helicopter.mts':
   Duration: 00:00:04.80, start: 0.841589, bitrate: 17066 kb/s
   Program 1
     Stream #0:0[0x1011], 118, 1/90000: Video: h264 (High) (HDMV /
 0x564D4448), yuv420p, 1920x1080 [SAR 1:1 DAR 16:9], 25 fps, 25 tbr, 90k
 tbn, 50 tbc
     Stream #0:1[0x1100], 67, 1/90000: Audio: ac3 (AC-3 / 0x332D4341),
 48000 Hz, stereo, fltp, 256 kb/s
     Stream #0:2[0x1200], 25, 1/90000: Subtitle: hdmv_pgs_subtitle
 ([144][0][0][0] / 0x0090), 1920x1080
 Successfully opened the file.
 Parsing a group of options: output file helicopter.mkv.
 Applying option f (force format) with argument matroska.
 Applying option c (codec name) with argument copy.
 Successfully parsed a group of options.
 Opening an output file: helicopter.mkv.
 Successfully opened the file.
 Output #0, matroska, to 'helicopter.mkv':
   Metadata:
     encoder         : Lavf56.19.100
     Stream #0:0, 0, 1/1000: Video: h264 (H264 / 0x34363248), yuv420p,
 1920x1080 [SAR 1:1 DAR 16:9], q=2-31, 25 fps, 25 tbr, 1k tbn, 90k tbc
     Stream #0:1, 0, 1/1000: Audio: ac3 ([0] [0][0] / 0x2000), 48000 Hz,
 stereo, 256 kb/s
 Stream mapping:
   Stream #0:0 -> #0:0 (copy)
   Stream #0:1 -> #0:1 (copy)
 Press [q] to stop, [?] for help
 [matroska @ 0x8fad20] Writing block at offset 808, size 184245, pts 120,
 dts 0, duration 20, flags 128
 [matroska @ 0x8fad20] Starting new cluster at offset 185061 bytes, pts
 9223372036854775808dts 20
 [matroska @ 0x8fad20] Can't write packet with unknown timestamp
 av_interleaved_write_frame(): Invalid argument
 No more output streams to write to, finishing.
 [matroska @ 0x8fad20] Writing block at offset 185076, size 61542, pts 40,
 dts 40, duration 20, flags 0
 [matroska @ 0x8fad20] Starting new cluster at offset 246626 bytes, pts
 9223372036854775808dts 60
 [matroska @ 0x8fad20] Writing block at offset 246641, size 1024, pts 40,
 dts 40, duration 32, flags 128
 [matroska @ 0x8fad20] Can't write packet with unknown timestamp
 [matroska @ 0x8fad20] end duration = 140
 frame=   24 fps=0.0 q=-1.0 Lsize=     242kB time=00:00:00.42
 bitrate=4718.1kbits/s
 video:836kB audio:1kB subtitle:0kB other streams:0kB global headers:1kB
 muxing overhead: unknown
 Input file #0 (helicopter.mts):
   Input stream #0:0 (video): 24 packets read (855988 bytes);
   Input stream #0:1 (audio): 1 packets read (1024 bytes);
   Input stream #0:2 (subtitle): 0 packets read (0 bytes);
   Total: 25 packets (857012 bytes) demuxed
 Output file #0 (helicopter.mkv):
   Output stream #0:0 (video): 24 packets muxed (855988 bytes);
   Output stream #0:1 (audio): 1 packets muxed (1024 bytes);
   Total: 25 packets (857012 bytes) muxed
 0 frames successfully decoded, 0 decoding errors
 [AVIOContext @ 0x8fbd80] Statistics: 20 seeks, 24 writeouts
 [AVIOContext @ 0x8f3680] Statistics: 6852752 bytes read, 2 seeks
 Conversion failed!
 }}}

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


More information about the FFmpeg-trac mailing list