goutubedl
goutubedl copied to clipboard
Specify start and end times
I see in the code there's specifiers for Start and End times, is there a way to use these options? I can't see any functions that take the Info type
You mean StartTime
/EndTime
in the Info
struct? I haven't actually notice them before. No they come from yt-dlp/youtubedl and are optionally populated by an extractor i think. Do you know if yt-dlp/youtubedl respect them and trim etc? also do you have any example of a URL that populate them?
yt-dlp respects them; I'm not sure about youtube-dl. I'm not sure exactly what you mean but here is an example command that does result in a clipped video yt-dlp "https://www.youtube.com/watch?v=dQw4w9WgXcQ" --download-sections "*0:03-0:10"
Sorry i ment if the start_time/end_time provided by a extractor is used for some kind of trimming. For example i don't see the youtube extractor sets any start_time for the example URL:
$ yt-dlp -J "https://www.youtube.com/watch?v=dQw4w9WgXcQ" | grep start_time
<no lines>
But looking quickly at the yt-dlp code it seems like --download-sections
might be using them. So to support this i think goutubedl have to add some kind of DownloadSections
option, but i'm a bit unsure how it would work and if the way gotoutubedl uses streaming via stdout makes i impossible or not.