[FFmpeg-user] Application provided invalid, non monotonically increasing dts to muxer in stream
MrNice
wxcvbn2006 at iol.ie
Sun Sep 27 10:47:08 CEST 2015
On 26/09/15 14:14, MrNice wrote:
> Attention to Carl Eugen
> and other experts,
>
> I did lot of tests and answered your last question.
> I didn't get any feedback so far, maybe you missed them.
> I need to go further in my project but I don't know what to do now to
> avoid the errors.
>
> Thank you to have a look and advice.
>
More tests:
So far I used the CL:
./ffmpeg -debug 1 -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 -g 1 -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"
I get errors, ie: 8133 input video packets (around 5 minutes) and drop=4
[matroska @ 0x3910d80] Writing block at offset 2449025254, size 53920,
pts 325664, dts 325664, duration 306, keyframe 1
[matroska @ 0x3910d80] end duration = 325970
[matroska @ 0x3910d80] stream 0 end duration = 325600
[matroska @ 0x3910d80] stream 1 end duration = 325970
frame= 8129 fps= 25 q=-0.0 Lq=-0.0 size= 2391845kB time=00:05:25.76
bitrate=60146.9kbits/s dup=0 drop=4
video:8923049kB audio:56154kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: unknown
Input file #0 (alsa_input.pci-0000_00_14.2.analog-stereo):
Input stream #0:0 (audio): 1173 packets read (57501184 bytes); 1173
frames decoded (14375296 samples);
Total: 1173 packets (57501184 bytes) demuxed
Input file #1 (/dev/video0):
Input stream #1:0 (video): 8133 packets read (6745835520 bytes); 8133
frames decoded;
Total: 8133 packets (6745835520 bytes) demuxed
Output file #0 (/Store3/Test/t_20150927_0925.mkv):
Output stream #0:0 (video): 8129 frames encoded; 8129 packets muxed
(2391366165 bytes);
Output stream #0:1 (audio): 1173 frames encoded (14375296 samples);
1173 packets muxed (57501184 bytes);
Total: 9302 packets (2448867349 bytes) muxed
Output file #1 (Dazzle output):
Output stream #1:0 (video): 8133 frames encoded; 8133 packets muxed
(6745835520 bytes);
Total: 8133 packets (6745835520 bytes) muxed
9306 frames successfully decoded, 0 decoding errors
[AVIOContext @ 0x391da40] Statistics: 48794 seeks, 111065 writeouts
Conversion failed!
When I write video first in the CL:
./ffmpeg -debug 1 -xerror -f v4l2 -ts mono2abs -channel 1 -video_size
720x576 -pix_fmt yuyv422 -thread_queue_size 512 -i /dev/video0 -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 -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 -g 1 -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"
I get errors, ie: 97 input video packets (around 5 seconds)) and drop=13
[matroska @ 0x2360ce0] Writing block at offset 19532162, size 65472, pts
4059, dts 4059, duration 371, keyframe 1
[matroska @ 0x2360ce0] end duration = 4430
[matroska @ 0x2360ce0] stream 0 end duration = 4080
[matroska @ 0x2360ce0] stream 1 end duration = 4430
frame= 84 fps= 17 q=-0.0 Lq=-0.0 size= 19140kB time=00:00:04.23
bitrate=37067.2kbits/s dup=0 drop=13
video:96942kB audio:763kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: unknown
Input file #0 (/dev/video0):
Input stream #0:0 (video): 97 packets read (80455680 bytes); 97 frames
decoded;
Total: 97 packets (80455680 bytes) demuxed
Input file #1 (alsa_input.pci-0000_00_14.2.analog-stereo):
Input stream #1:0 (audio): 15 packets read (781464 bytes); 15 frames
decoded (195366 samples);
Total: 15 packets (781464 bytes) demuxed
Output file #0 (/Store3/Test/t_20150927_0933.mkv):
Output stream #0:0 (video): 84 frames encoded; 84 packets muxed
(18813101 bytes);
Output stream #0:1 (audio): 15 frames encoded (195366 samples); 15
packets muxed (781464 bytes);
Total: 99 packets (19594565 bytes) muxed
Output file #1 (Dazzle output):
Output stream #1:0 (video): 97 frames encoded; 97 packets muxed
(80455680 bytes);
Total: 97 packets (80455680 bytes) muxed
112 frames successfully decoded, 0 decoding errors
[AVIOContext @ 0x2375b60] Statistics: 524 seeks, 968 writeouts
Conversion failed!
Video first leads to a lot more errors and dropped frames.
BTW, 1 week ago, I opened a bug, so far no answer
https://trac.ffmpeg.org/ticket/4869#no1
More information about the ffmpeg-user
mailing list