[FFmpeg-user] Application provided invalid, non monotonically increasing dts to muxer in stream

MrNice wxcvbn2006 at iol.ie
Sun Sep 20 14:06:24 CEST 2015


On 20/09/15 11:41, MrNice wrote:
> On 19/09/15 18:16, MrNice wrote:
>>
>>
>> On 19/09/15 18:02, MrNice wrote:
>>>
>>>
>>> On 17/09/15 14:51, MrNice wrote:
>>>>
>>>>
>>>> On 17/09/15 12:00, Carl Eugen Hoyos wrote:
>>>>> MrNice <wxcvbn2006 <at> iol.ie> writes:
>>>>>
>>>>>>> Does it also happen if you only record audio?
>>>>>>
>>>>>> Yes it happen with the command
>>>>>> ./ffmpeg 
>>>>>
>>>>>> -f v4l2 -ts mono2abs -channel 1 -video_size 720x576 
>>>>>> -pix_fmt yuyv422 -thread_queue_size 512 -i /dev/video0
>>>>>
>>>>> Does it also happen if you only provide audio 
>>>>> input to FFmpeg?
>>>>>
>>>>> Carl Eugen
>>>>>
>>>>>
>>>>
>>>> No error in a 50 mn recording with command
>>>> ./ffmpeg -debug 1 -f pulse -ar 44100 -ac 2 -channel_layout stereo
>>>> -thread_queue_size 512 -itsoffset -0.20 -i
>>>> alsa_input.pci-0000_00_14.2.analog-stereo -vn -c:a pcm_s16le
>>>> /Store3/Test/t_`date +%Y%m%d_%H%M`.mkv
>>>>
>>>
>>>
>>> More info after long tests.
>>> The error
>>> Application provided invalid, non monotonically increasing dts to muxer
>>> in stream 0:
>>> happens after at least 30 minutes recording. ie: Last time at 33:12
>>> Few seconds before or after happens warning message
>>> Past duration 0.xxxx too large
>>>
>>> Following this link
>>> http://ffmpeg.org/pipermail/ffmpeg-user/2014-December/024695.html
>>> I tried with -af aresample=async=1 but still I get the error with 1
>>> frame dropped.
>>>
>>> [matroska @ 0x25d9de0] Writing block at offset 9113825634, size 179818,
>>> pts 2026200, dts 2026200, duration 40, keyframe 0
>>> [matroska @ 0x25d9de0] Writing block at offset 9114005460, size 176978,
>>> pts 2026240, dts 2026240, duration 40, keyframe 0
>>> Past duration 0.602318 too large
>>> *** dropping frame 50652 from stream 0 at ts 50650
>>> [matroska @ 0x25d9de0] Starting new cluster at offset 9114182446 bytes,
>>> pts 2026280dts 2026280
>>> [matroska @ 0x25d9de0] Writing block at offset 9114182463, size 180336,
>>> pts 2026280, dts 2026280, duration 40, keyframe 1
>>> Past duration 0.601341 too large
>>>
>>> What more to do?
>>>
>>> As the errors are after 30 minutes, I could try to record by smaller
>>> parts. To be sure, I would like a way to stop recording if an error
>>> occurs. I tried -xerror but it's not working with this error.
>>> Any idea how to do?
>>> _
>>
>>
>> I was wrong: One more try and I got the error at 8:07
>>
>> I need help!!!
>>
>>
> 
> More info, hope this will help to find a fix or a workaround.
> 
> So far I used a DVD player to test and I had usually the errors after 30
> minutes capture.
> In fact the use case is with a S-VHS player. When I capture from blank
> tape (statics before the images appear) I get a lot of errors and frame
> drops, then errors stop when the images appear.
> Same appends as well (not always) when there is a change betweens 2
> takes or when there is a drop in the tape.
> 
> Is it the right behaviour?
> 
> 


More info, new test.

>From my S-VHS player, when there is no tape inside, there is a blue
image with program number in white. This is a still image, stable
without any static.
I captured this image and got errors and drops at very regular time.
Looking at the output log, I took the time for 15 errors. All of them
are separated by 16-17 seconds.
Between the errors there are warning messages
Past duration 0.xxxxx too large
where 0.xxxxx increase at a regular time.


./ffmpeg -loglevel info -xerror -f pulse -ar 44100 -ac 2 -channel_layout
stereo -thread_queue_size 512 -itsoffset -0.20 -i
alsa_input.pci-0000_00_14.2.analog-stereo -f v4l2 -ts mono2abs -channel
1 -video_size 720x576 -pix_fmt yuyv422 -thread_queue_size 512 -i
/dev/video0 -vf
drawbox=0:0:3:576:black at 1:t=max,drawbox=718:0:3:576:black at 1:t=max,drawbox=0:0:720:3:black at 1:t=max,drawbox=0:564:720:12:black at 1:t=max
-c:v ffv1 -level 3 -aspect 4:3 -pix_fmt yuv422p -c:a pcm_s16le
/Store3/Test/t_`date +%Y%m%d_%H%M`.mkv -aspect 4:3 -f sdl "Dazzle output"
ffmpeg version N-75272-g5629143 Copyright (c) 2000-2015 the FFmpeg
developers
  built with gcc 5.1.1 (GCC) 20150618 (Red Hat 5.1.1-4)
  configuration: --enable-libpulse --enable-gpl --enable-libx264
  libavutil      55.  2.100 / 55.  2.100
  libavcodec     57.  1.100 / 57.  1.100
  libavformat    57.  0.100 / 57.  0.100
  libavdevice    57.  0.100 / 57.  0.100
  libavfilter     6.  2.100 /  6.  2.100
  libswscale      4.  0.100 /  4.  0.100
  libswresample   2.  0.100 /  2.  0.100
  libpostproc    54.  0.100 / 54.  0.100
Input #0, pulse, from 'alsa_input.pci-0000_00_14.2.analog-stereo':
  Duration: N/A, start: 1442747383.881984, bitrate: 1411 kb/s
    Stream #0:0: Audio: pcm_s16le, 44100 Hz, stereo, s16, 1411 kb/s
[video4linux2,v4l2 @ 0x38d82e0] Detected monotonic timestamps, converting
Input #1, video4linux2,v4l2, from '/dev/video0':
  Duration: N/A, start: 1442747385.038588, bitrate: 165888 kb/s
    Stream #1:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 720x576,
165888 kb/s, 25 fps, 25 tbr, 1000k tbn, 1000k tbc
Output #0, matroska, to '/Store3/Test/t_20150920_1209.mkv':
  Metadata:
    encoder         : Lavf57.0.100
    Stream #0:0: Video: ffv1 (FFV1 / 0x31564646), yuv422p, 720x576 [SAR
16:15 DAR 4:3], q=2-31, 200 kb/s, 25 fps, 1k tbn, 25 tbc
    Metadata:
      encoder         : Lavc57.1.100 ffv1
    Stream #0:1: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 44100 Hz,
stereo, s16, 1411 kb/s
    Metadata:
      encoder         : Lavc57.1.100 pcm_s16le
Output #1, sdl, to 'Dazzle output':
  Metadata:
    encoder         : Lavf57.0.100
    Stream #1:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 720x576
[SAR 16:15 DAR 4:3], q=2-31, 200 kb/s, 25 fps, 25 tbn, 25 tbc
    Metadata:
      encoder         : Lavc57.1.100 rawvideo
Stream mapping:
  Stream #1:0 -> #0:0 (rawvideo (native) -> ffv1 (native))
  Stream #0:0 -> #0:1 (pcm_s16le (native) -> pcm_s16le (native))
  Stream #1:0 -> #1:0 (rawvideo (native) -> rawvideo (native))
Press [q] to stop, [?] for help
Past duration 0.628471 too large0 size=   44319kB time=00:00:09.71
bitrate=37386.8kbits/s
[sdl @ 0x38fef00] Application provided invalid, non monotonically
increasing dts to muxer in stream 0: 232 >= 232
Past duration 0.626991 too large
Past duration 0.629173 too large
Past duration 0.628471 too large
Past duration 0.627617 too large
Past duration 0.627922 too large
Past duration 0.628044 too large
Past duration 0.628120 too large
    Last message repeated 1 times
Past duration 0.630318 too large
Past duration 0.629219 too large
Past duration 0.628685 too large
Past duration 0.628319 too large0 size=   46793kB time=00:00:09.86
bitrate=38873.3kbits/s
Past duration 0.630318 too large
Past duration 0.630913 too large
Past duration 0.631416 too large
Past duration 0.629585 too large
Past duration 0.627922 too large
Past duration 0.631538 too large
Past duration 0.630440 too large
Past duration 0.629936 too large
Past duration 0.631660 too large
Past duration 0.632164 too large
Past duration 0.630516 too large
Past duration 0.630287 too large
Past duration 0.630714 too large0 size=   49324kB time=00:00:10.84
bitrate=37271.6kbits/s
Past duration 0.632790 too large
Past duration 0.631187 too large
Past duration 0.631325 too large
Past duration 0.631096 too large
Past duration 0.631737 too large
Past duration 0.631447 too large
Past duration 0.631767 too large
Past duration 0.631935 too large
Past duration 0.632088 too large
Past duration 0.632072 too large
Past duration 0.633919 too large
Past duration 0.634346 too large
Past duration 0.632866 too large0 size=   51755kB time=00:00:11.21
bitrate=37814.7kbits/s
Past duration 0.632713 too large
Past duration 0.634544 too large
Past duration 0.633171 too large
Past duration 0.633247 too large
Past duration 0.635017 too large
Past duration 0.633568 too large
Past duration 0.633766 too large
Past duration 0.633919 too large
Past duration 0.634087 too large
Past duration 0.634148 too large
Past duration 0.634422 too large
Past duration 0.634514 too large0 size=   53658kB time=00:00:11.36
bitrate=38687.6kbits/s
Past duration 0.634712 too large
Past duration 0.634895 too large
Past duration 0.634819 too large
Past duration 0.637169 too large
Past duration 0.635170 too large
Past duration 0.637596 too large
Past duration 0.635719 too large
Past duration 0.635414 too large
Past duration 0.637367 too large
Past duration 0.635963 too large
Past duration 0.636238 too large
Past duration 0.636040 too large
Past duration 0.636467 too large0 size=   56332kB time=00:00:12.17
bitrate=37918.9kbits/s
Past duration 0.636513 too large
Past duration 0.636696 too large
Past duration 0.636894 too large
Past duration 0.638496 too large
Past duration 0.637123 too large
Past duration 0.637367 too large
Past duration 0.637535 too large
Past duration 0.639015 too large
Past duration 0.639168 too large
Past duration 0.637535 too large
Past duration 0.637886 too large
Past duration 0.638039 too large
Past duration 0.637886 too large0 size=   59000kB time=00:00:12.71
bitrate=38018.4kbits/s
Past duration 0.638390 too large
Past duration 0.638420 too large
Past duration 0.638618 too large
Past duration 0.638649 too large
Past duration 0.638817 too large
Past duration 0.638786 too large
Past duration 0.639473 too large
Past duration 0.639015 too large
Past duration 0.840187 too large
Past duration 0.837669 too large
Past duration 0.838219 too large0 size=   60723kB time=00:00:12.86
bitrate=38672.5kbits/s
Past duration 0.837761 too large
Past duration 0.837914 too large
Past duration 0.838036 too large
Past duration 0.840691 too large
Past duration 0.838341 too large
Past duration 0.840736 too large
Past duration 0.839943 too large
Past duration 0.841225 too large
Past duration 0.841072 too large
Past duration 0.841362 too large
    Last message repeated 1 times
Past duration 0.840691 too large
Past duration 0.839165 too large
Past duration 0.842125 too large
Past duration 0.840446 too large0 size=   64001kB time=00:00:13.79
bitrate=37998.3kbits/s
Past duration 0.841988 too large
Past duration 0.842415 too large
Past duration 0.840370 too large
Past duration 0.840416 too large
Past duration 0.840248 too large
Past duration 0.840736 too large
Past duration 0.840965 too large
Past duration 0.842613 too large
Past duration 0.841713 too large
Past duration 0.841270 too large
Past duration 0.841469 too large
Past duration 0.841560 too large
Past duration 0.843849 too large0 size=   66247kB time=00:00:14.21
bitrate=38180.6kbits/s
Past duration 0.841972 too large
Past duration 0.837975 too large
Past duration 0.844490 too large
Past duration 0.842293 too large
Past duration 0.844688 too large
Past duration 0.843987 too large
Past duration 0.844719 too large
Past duration 0.842949 too large
Past duration 0.845268 too large
Past duration 0.845192 too large0 size=   67965kB time=00:00:14.36
bitrate=38758.7kbits/s
Past duration 0.843498 too large
Past duration 0.843666 too large
Past duration 0.845573 too large
Past duration 0.845543 too large
Past duration 0.846046 too large
Past duration 0.846214 too large
Past duration 0.845940 too large
Past duration 0.846596 too large
Past duration 0.846687 too large
Past duration 0.846443 too large
Past duration 0.844917 too large
Past duration 0.847069 too large
Past duration 0.845146 too large
Past duration 0.847221 too large
Past duration 0.845390 too large0 size=   71245kB time=00:00:15.34
bitrate=38034.5kbits/s
Past duration 0.845436 too large
Past duration 0.845741 too large
Past duration 0.845863 too large
Past duration 0.846062 too large
Past duration 0.846138 too large
Past duration 0.848045 too large
Past duration 0.846443 too large
Past duration 0.846596 too large
Past duration 0.846748 too large
Past duration 0.846916 too large
Past duration 0.847099 too large
Past duration 0.847237 too large
Past duration 0.847435 too large0 size=   73740kB time=00:00:15.79
bitrate=38235.0kbits/s
Past duration 0.849388 too large
Past duration 0.847588 too large
Past duration 0.849464 too large
Past duration 0.849495 too large
Past duration 0.849724 too large
Past duration 0.848061 too large
Past duration 0.848244 too large
Past duration 0.848412 too large
Past duration 0.848442 too large
Past duration 0.848488 too large
Past duration 0.848671 too large0 size=   75791kB time=00:00:16.23
bitrate=38238.4kbits/s
Past duration 0.848869 too large
Past duration 0.850838 too large
Past duration 0.849037 too large
Past duration 0.849098 too large
[sdl @ 0x38fef00] Application provided invalid, non monotonically
increasing dts to muxer in stream 0: 654 >= 654
Past duration 0.677971 too large
Past duration 0.678261 too large
Past duration 0.678169 too large
Past duration 0.678566 too large
Past duration 0.678642 too large
Past duration 0.681389 too large
Past duration 0.678017 too large
Past duration 0.679070 too large
Past duration 0.679192 too large
Past duration 0.679710 too large
Past duration 0.681267 too large0 size=  127127kB time=00:00:27.11
bitrate=38404.9kbits/s dup=0 drop=1
Past duration 0.681236 too large
Past duration 0.679787 too large
Past duration 0.679420 too large




More information about the ffmpeg-user mailing list