将输入拆分为 NAL 单元时出错,视频损坏?

将输入拆分为 NAL 单元时出错,视频损坏?

我正在尝试玩这个视频我通过 youtube-dl 下载了它。

$ youtube-dl --verbose -c -f 22 SYahi3XFEa4
[debug] System config: []
[debug] User config: [u'-f', u'bestvideo[height<=720]+bestaudio/best[height<=720]']
[debug] Custom config: []
[debug] Command-line args: [u'--verbose', u'-c', u'-f', u'22', u'SYahi3XFEa4']
[debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8
[debug] youtube-dl version 2019.11.28
[debug] Python version 2.7.17 (CPython) - Linux-5.3.0-2-amd64-x86_64-with-debian-bullseye-sid
[debug] exe versions: ffmpeg 4.2.1-2, ffprobe 4.2.1-2, phantomjs 2.1.1, rtmpdump 2.4
[debug] Proxy map: {}
[youtube] SYahi3XFEa4: Downloading webpage
[youtube] SYahi3XFEa4: Downloading video info webpage

它会下载整个视频,但当我过一会儿开始播放时,收到此消息 -

Error while decoding stream #0:1: Invalid data found when processing input
[aac @ 0x55b8592a73c0] Sample rate index in program config element does not match the sample rate index configured by the container.
[aac @ 0x55b8592a73c0] Inconsistent channel configuration.
[aac @ 0x55b8592a73c0] get_buffer() failed
Error while decoding stream #0:1: Invalid argument
[aac @ 0x55b8592a73c0] Reserved bit set.
[aac @ 0x55b8592a73c0] Number of bands (62) exceeds limit (45).
Error while decoding stream #0:1: Invalid data found when processing input
[aac @ 0x55b8592a73c0] channel element 3.0 is not allocated
[aac @ 0x55b8592a73c0] channel element 3.15 is not allocated
Error while decoding stream #0:1: Invalid data found when processing input
[aac @ 0x55b8592a73c0] Reserved bit set.
[aac @ 0x55b8592a73c0] Prediction is not allowed in AAC-LC.
Error while decoding stream #0:1: Invalid data found when processing input
[aac @ 0x55b8592a73c0] Prediction is not allowed in AAC-LC.
Error while decoding stream #0:1: Invalid data found when processing input
[aac @ 0x55b8592a73c0] channel element 3.11 is not allocated
Error while decoding stream #0:1: Invalid data found when processing input
[aac @ 0x55b8592a73c0] channel element 3.12 is not allocated
Error while decoding stream #0:1: Invalid data found when processing input

这种情况一直持续下去。如果我尝试使用 ffmpeg 修复有问题的视频,它只能修复视频的前 10-15 分钟,其余视频仍然损坏,即无法看到或听到。

例如,这是我尝试播放整个文件时得到的结果 -

$ mpv output.mp4 
 (+) Video --vid=1 (*) (h264 1280x720 29.970fps)
 (+) Audio --aid=1 --alang=eng (*) (aac 2ch 44100Hz)
AO: [pulse] 44100Hz stereo 2ch float
VO: [gpu] 1280x720 yuv420p
AV: 00:26:15 / 00:28:56 (90%) A-V:  0.000
Invalid audio PTS: 260.620771 -> 381.016236
Invalid audio PTS: 381.039456 -> 413.361633
Invalid audio PTS: 413.384853 -> 430.753379
Invalid audio PTS: 430.776599 -> 517.247710
Invalid audio PTS: 517.270930 -> 584.701678
Reset playback due to audio timestamp reset.
Invalid audio PTS: 601.141406 -> 601.838005
Invalid audio PTS: 601.861224 -> 610.475828
Invalid audio PTS: 610.499048 -> 613.958821
Invalid audio PTS: 613.982041 -> 620.158549
Invalid audio PTS: 620.181769 -> 631.675646
Invalid audio PTS: 631.698866 -> 641.822766
Invalid audio PTS: 641.845986 -> 675.189841
Invalid audio PTS: 675.213061 -> 686.962358
Reset playback due to audio timestamp reset.
Invalid audio PTS: 719.029116 -> 750.283175
Invalid audio PTS: 750.306395 -> 755.368345
Invalid audio PTS: 755.391565 -> 807.009524
Invalid audio PTS: 807.032744 -> 815.949206
Invalid audio PTS: 815.972426 -> 945.725533
Invalid audio PTS: 945.748753 -> 1048.450612
Invalid audio PTS: 1048.473832 -> 1153.079728
Invalid audio PTS: 1153.102948 -> 1154.194286
Reset playback due to audio timestamp reset.
Invalid audio PTS: 1175.092245 -> 1175.231565
Invalid audio PTS: 1175.254785 -> 1184.380227
Invalid audio PTS: 1184.403447 -> 1196.059864
Invalid audio PTS: 1196.083084 -> 1283.041814
Invalid audio PTS: 1283.065034 -> 1297.020227
Invalid audio PTS: 1297.043447 -> 1343.320816
Invalid audio PTS: 1343.344036 -> 1388.460408
Invalid audio PTS: 1388.483628 -> 1472.539864
Reset playback due to audio timestamp reset.
Invalid audio PTS: 1479.621950 -> 1480.875828
Invalid audio PTS: 1480.899048 -> 1532.679546
Invalid audio PTS: 1532.702766 -> 1570.922812
Invalid audio PTS: 1570.946032 -> 1595.257324
Invalid audio PTS: 1595.280544 -> 1647.943401
Invalid audio PTS: 1647.966621 -> 1736.643628
Reset playback due to audio timestamp reset.

任何关于这里可能出现什么问题的线索。FFmpeg 是 Debian 上最新的 4.2 版本。

相关内容