[FFmpeg-user] Properly download/trim a hls-stream which reports invalid timestamps
Reino Wijnsma
rwijnsma at xs4all.nl
Sun Nov 19 12:19:08 EET 2017
On 18-11-2017 2:46, Moritz Barsnick <barsnick at gmx.net> wrote:
> In order not to have youtube-dl remux the downloaded, reassembled
> MPEG-TS to MP4, add "--fixup never".
>
> Have you managed to hand an arbitrary m3u8 URL to youtube-dl for
> download? I'd love to use it that way, but youtube-dl sometimes doesn't
> get my point.
youtube-dl.exe --hls-prefer-native --fixup never -o "temp.ts" "http://manifest.us.rtl.nl/10/v166/aes/adaptive/components/actueel/rtlnieuws/376457/2017w46/da93fffe-8f2e-3db7-ac4c-5d03a610b188.ssm/da93fffe-8f2e-3db7-ac4c-5d03a610b188.ism/da93fffe-8f2e-3db7-ac4c-5d03a610b188-audio=125437-video=3955000.m3u8"
[generic] da93fffe-8f2e-3db7-ac4c-5d03a610b188-audio=125437-video=3955000: Requesting header
[generic] da93fffe-8f2e-3db7-ac4c-5d03a610b188-audio=125437-video=3955000: Downloading m3u8 information
[hlsnative] Downloading m3u8 manifest
[hlsnative] Total fragments: 124
[download] Destination: temp.ts
[download] 100% of 617.80MiB in 05:43
This works just fine.
ffplay.exe -hide_banner -i temp.ts
[AVBSFContext @ 04cbf6c0] Invalid NAL unit 0, skipping. 0B f=0/0
Input #0, mpegts, from '..\temp.mp4':
Duration: 00:20:33.48, start: 10.000000, bitrate: 4201 kb/s
Program 16727
Stream #0:0[0x22]: Audio: aac (LC) ([15][0][0][0] / 0x000F), 48000 Hz, stereo, fltp, 135 kb/s
Stream #0:1[0x21]: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p(progressive), 1280x720 [
SAR 1:1 DAR 16:9], 25 fps, 25 tbr, 90k tbn, 50 tbc
[mpegts @ 04c93de0] Invalid timestamps stream=1, pts=975600, dts=979200, size=16711
[mpegts @ 04c93de0] Invalid timestamps stream=1, pts=982800, dts=986400, size=15911
[mpegts @ 04c93de0] Invalid timestamps stream=1, pts=993600, dts=997200, size=22021
[mpegts @ 04c93de0] Invalid timestamps stream=1, pts=997200, dts=1000800, size=14509
[mpegts @ 04c93de0] Invalid timestamps stream=1, pts=1004400, dts=1008000, size=20138
[mpegts @ 04c93de0] Invalid timestamps stream=1, pts=1008000, dts=1011600, size=13316
[...]
But is doesn't do anything about the initial problem.
I'm not sure why 'Carl Eugen Hoyos' asked me to check up on other tools in the first place. This is the FFmpeg mailing list.
-- Reino
More information about the ffmpeg-user
mailing list