Opened 5 weeks ago

Last modified 5 weeks ago

#7144 new defect

mpeg-dash - Application provided duration: -1056 / timestamp: 983056 is out of range for mov/mp4 format

Reported by: andreymal Owned by:
Priority: normal Component: undetermined
Version: git-master Keywords: dash
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

I have an IP Camera: Falcon Eye FE-MTR300-HD. And I want to remux RTSP camera stream to MPEG-DASH stream for web browsers, but it breaks after few hours. I guess this error can be the cause.

$ ffmpeg -loglevel warning -i [input-stream] -c:v copy -an -f dash -seg_duration 2 dash/manifest.mpd
[dash @ 0x3b194c0] No bit rate set for stream 0
[mp4 @ 0x3bec8c0] Application provided duration: -544 / timestamp: 32528 is out of range for mov/mp4 format
[mp4 @ 0x3bec8c0] Application provided duration: -528 / timestamp: 80544 is out of range for mov/mp4 format
[mp4 @ 0x3bec8c0] Application provided duration: -528 / timestamp: 128544 is out of range for mov/mp4 format
... and many other lines, one per segment ...

I also tried -avoid_negative_ts make_non_negative and/or -fflags +genpts, but nothing changed.

ffmpeg ... -c copy test.mp4 or ffmpeg ... -f segment %07d.mp4 works without errors, so I think this is dash bug.

I do not exclude that the problem is in the camera and the stream may be broken, but I can't influence it. (Can ffmpeg fix the broken stream without transcoding, please? :)

This problem affects any ffmpeg >=3.4 version, including latest git-2018-04-17-2fc12f4 (tested on Ubuntu 16.04 and Debian 8)

P.S. Possible duplicate of #6778, but I can provide additional information; see attached dash_mp4_timestamp_error.flv to reproduce this (grabbed from original RTSP stream).

P.P.S. Default loglevel, if you want:

$ ffmpeg -i dash_mp4_timestamp_error.flv -c:v copy -an -f dash -seg_duration 2 dash/manifest.mpd
ffmpeg version git-2018-04-17-2fc12f4 Copyright (c) 2000-2018 the FFmpeg developers
  built with gcc 5.4.0 (Ubuntu 5.4.0-6ubuntu1~16.04.9) 20160609
  configuration: --prefix=/home/andreymal/ffmpeg_build --pkg-config-flags=--static
         --extra-cflags=-I/home/andreymal/ffmpeg_build/include
         --extra-ldflags=-L/home/andreymal/ffmpeg_build/lib
         --extra-libs='-lpthread -lm' --bindir=/home/andreymal/bin
         --enable-gpl --enable-libass --enable-libfdk-aac --enable-libfreetype
         --enable-libmp3lame --enable-libopus --enable-libtheora --enable-libvorbis
         --enable-libx264 --enable-nonfree
  libavutil      56. 15.100 / 56. 15.100
  libavcodec     58. 19.100 / 58. 19.100
  libavformat    58. 13.100 / 58. 13.100
  libavdevice    58.  4.100 / 58.  4.100
  libavfilter     7. 18.100 /  7. 18.100
  libswscale      5.  2.100 /  5.  2.100
  libswresample   3.  2.100 /  3.  2.100
  libpostproc    55.  2.100 / 55.  2.100
Input #0, flv, from 'test.flv':
  Metadata:
    title           : 10
    encoder         : Lavf57.83.100
  Duration: 00:02:57.25, start: 3.301000, bitrate: 190 kb/s
    Stream #0:0: Video: h264 (Main), yuv420p(progressive), 1280x720, 30 tbr, 1k tbn
[dash @ 0x3910f80] No bit rate set for stream 0
[dash @ 0x3910f80] Opening 'dash/init-stream0.m4s' for writing
Output #0, dash, to 'dash/manifest.mpd':
  Metadata:
    title           : 10
    encoder         : Lavf58.13.100
    Stream #0:0: Video: h264 (Main), yuv420p(progressive), 1280x720, q=2-31, 30 tbr, 16k tbn, 1k tbc
Stream mapping:
  Stream #0:0 -> #0:0 (copy)
Press [q] to stop, [?] for help
[dash @ 0x3910f80] Opening 'dash/chunk-stream0-00001.m4s.tmp' for writing
[dash @ 0x3910f80] Opening 'dash/manifest.mpd.tmp' for writing
[mp4 @ 0x39d6a80] Application provided duration: -544 / timestamp: 32528 is out of range for mov/mp4 format
[dash @ 0x3910f80] Opening 'dash/chunk-stream0-00002.m4s.tmp' for writing
[dash @ 0x3910f80] Opening 'dash/manifest.mpd.tmp' for writing
[mp4 @ 0x39d6a80] Application provided duration: -528 / timestamp: 80544 is out of range for mov/mp4 format

... many similar lines ...

[mp4 @ 0x39d6a80] Application provided duration: -1056 / timestamp: 2780048 is out of range for mov/mp4 format
[dash @ 0x3910f80] Opening 'dash/chunk-stream0-00065.m4s.tmp' for writing
[dash @ 0x3910f80] Opening 'dash/manifest.mpd.tmp' for writing
[mp4 @ 0x39d6a80] Application provided duration: -1056 / timestamp: 2814720 is out of range for mov/mp4 format
[dash @ 0x3910f80] Opening 'dash/chunk-stream0-00066.m4s.tmp' for writing
[dash @ 0x3910f80] Opening 'dash/manifest.mpd.tmp' for writing
frame= 2079 fps=0.0 q=-1.0 Lsize=N/A time=00:02:57.25 bitrate=N/A speed=4.7e+03x    
video:4071kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown

Attachments (1)

dash_mp4_timestamp_error.flv (737.0 KB) - added by andreymal 5 weeks ago.
Grabbed from the RTSP stream of IP camera

Download all attachments as: .zip

Change History (2)

Changed 5 weeks ago by andreymal

Grabbed from the RTSP stream of IP camera

comment:1 Changed 5 weeks ago by cehoyos

The warning is shown since 51000b994514e64a6c5039e179f20c9e24f87c45

Note: See TracTickets for help on using tickets.