ytdl-org / youtube-dl

Command-line program to download videos from YouTube.com and other video sites
http://ytdl-org.github.io/youtube-dl/
The Unlicense
132k stars 10.01k forks source link

Ability to download segmented videos from archive.org #29603

Open icsllcweb opened 3 years ago

icsllcweb commented 3 years ago

Checklist

Description

WRITE DESCRIPTION HERE Some of the videos stored on archive.org appear to be partitioned into one minute sections. Youtube-dl appears to be able to download them individually, but it does not download them in bulk and piece them together. This would be very helpful for offline review and research. Here is an example video: https://archive.org/details/FOXNEWSW_20210619_050000_Tucker_Carlson_Tonight

ryanmcginnis commented 5 months ago

Hello @icsllcweb, I wrote a Bash script that accomplishes what you're looking for, if you'd like to try it out. I just used it to download the news segment you posted and it worked great for research purposes:

https://github.com/ryanmcginnis/adl

dirkf commented 5 months ago

So the solution to this issue requires:

  1. fetching as JSON the value of the attribute value from the element(s?) selected by #leftrite > input.js-tv3-init.
  2. extracting a multi-video playlist from ["TV3.clipstream_clips"] member of the JSON (a list of URLS like 'http://archive.org/download/FOXNEWSW_20210619_050000_Tucker_Carlson_Tonight/FOXNEWSW_20210619_050000_Tucker_Carlson_Tonight.mp4?t=0/60&ignore=x.mp4
  3. correctly processing the multi-video playlist by concatenating the streams from each AV MP4 segment.

Point 3 is what needs to be fixed, since 1 and 2 should be easy to add to the extractor.