Melanun Di Youtube
Kandungan:
Menulis ini sebagai nota takut hilang ilmu lanun yang berharga ni.
Download yt-dlp executable from Github.
Audio MP3 highest quality
Single
./yt-dlp.exe --extract-audio --output "%(title)s.%(ext)s" --audio-format mp3 --audio-quality 0 INSERT_URL
Batch download
./yt-dlp.exe --extract-audio --output "%(title)s.%(ext)s" --audio-format mp3 --audio-quality 0 -ci --batch-file=batch.txt
Cut duration
./yt-dlp.exe --extract-audio --output "%(title)s.%(ext)s" --audio-format mp3 --audio-quality 0 INSERT_URL --downloader ffmpeg --downloader-args "ffmpeg_i:-ss 00:10:07"
Example above, start at 10 minutes 7 seconds
Use ffmpeg_i:-ss 00:00:10.00 -t 00:00:30.00 to download only a specific duration (e.g., 30 seconds from the start time). -t specifies the duration of the resulting file, not an end time. Apa-apa, Google je.
Video highest quality
./yt-dlp.exe -f 'bestvideo[ext=mp4]+bestaudio[ext=m4a]/bestvideo+bestaudio' --merge-output-format mp4 INSERT_URL
Download a playlist
./yt-dlp.exe -i -f mp4 --yes-playlist PLAYLIST_URL
Cut video
./ffmpeg.exe -ss 262.2 -t 56.3 -i VIDEO_FILE.EXT -y -c copy OUTPUT_VIDEO.mp4
More info: https://ytcutter.cc/
-ss: set the start time ofkfset-t: record or transcode “duration” seconds of audio/video
NOTE: use yt-dlp.exe instead