List all available formats
youtube-d -F <id>
Download and mux the selected IDs
youtube-dl -f <video_id>+<audio_id> <id>
ffmpeg -i audio.m4a -metadata:s:a:0 language=<iso code> output.m4a
ffmpeg -i video.mp4 -i audio_1.m4a -i audio_2.m4a -map 0:0 -map 1:0 -map 2:0 -c:v copy -c:a copy output.mp4
ffmpeg -i $input_file -vcodec copy -an $output_file
ffmpeg -f avfoundation -capture_cursor 1 -i 3 -r 30 -c:v libx264 -an -tune zerolatency -preset ultrafast -pix_fmt yuv420p -fflags flush_packets -f mpegts - | mpv - --no-cache --untimed --no-demuxer-thread --video-sync=audio --vd-lavc-threads=1
ffmpeg -h encoder=h264_videotoolbox
cat ./init.mp4 ./test0.m4s | ffprobe -show_frames -
ffmpeg -ss <starttime> -i <mp4> -t <duration> output.mp4
ffmpeg -i <input> -vf scale=320:-1 <output>
Dash:
ffmpeg -re -stream_loop -1 -i ForBiggerBlazes.mp4 -c:v copy -c:a copy -f dash live.mpd
Hls:
ffmpeg -re -stream_loop -1 -i ForBiggerBlazes.mp4 -c:v copy -c:a copy -f hls live.m3u8
mpv <input> --no-cache --untimed --no-demuxer-thread --video-sync=audio --vd-lavc-threads=1
https://docs.microsoft.com/en-us/windows/win32/directshow/h-264-video-types?redirectedfrom=MSDN
// Copyright (c) 2015, Dash Industry Forum
function getH264Codec(codecPrivateData) {
// Extract from the CodecPrivateData field the hexadecimal representation of the following
// three bytes in the sequence parameter set NAL unit.
// => Find the SPS nal header
nalHeader = /00000001[0-9]7/.exec(codecPrivateData);
// => Find the 6 characters after the SPS nalHeader (if it exists)
avcoti = nalHeader && nalHeader[0] ? (codecPrivateData.substr(codecPrivateData.indexOf(nalHeader[0]) + 10, 6)) : undefined;
return 'avc1.' + avcoti;
}