Skip to main content

download_video

Function download_video 

Source
pub fn download_video<F>(
    url: &str,
    output_dir: &str,
    quality: &VideoQuality,
    quiet: bool,
    status_cb: Option<F>,
) -> Result<(), Box<dyn Error + Send + Sync>>
where F: Fn(String) + Send + Sync + 'static,
Expand description

Download a video URL using yt-dlp.

Streams yt-dlp’s progress lines through status_cb so callers can forward them to a progress bar or GUI.