Hot answers tagged

15

Answer Use two-pass Constant Quality mode:ยน ffmpeg -i input.mp4 -b:v 0 -crf 30 -pass 1 -an -f webm /dev/null ffmpeg -i input.mp4 -b:v 0 -crf 30 -pass 2 output.webm Explanation: Setting the video bitrate to zero while also specifying the CRF (Constant Rate Factor) enables Constant Quality mode which targets a certain perceptual quality level. For ...


13

tl;dr: Since Youtube reencodes all videos regardless of the upload format, it really isn't that important. Just export your video with a high bitrate to preserve quality. Also see my answer here regarding quality loss caused by Youtube. Long answer: Each reencoding of a video to a compressed format lowers the quality. Usually, that means you'll lose quality ...


7

YouTube will re-encode whatever you give it. VP9 is currently too slow to encode. So the best choice is to either: Give it the original footage, or if it is not accepted by YouTube or is too big to upload, then... Re-encode to H.264 ffmpeg ffmpeg will accept just about any input and will provide a great quality output. Development is very active, so it is ...


2

Rather than framerate, the issue is there's only one frame. You'll have to loop the image. ffmpeg -i Audio.opus -loop 1 -i image.png -pix_fmt yuv420p -ac 2 -s 640x360 -strict strict -r pal -shortest myAudioFile.webm -loop 1 : infinitely loops over the same image -shortest : stops encoding when the shortest input stream has entirely been encoded


2

YUV color encoding with 4:2:0 chroma subsampling is the only widely safe pixel format for web playback, although for certain codecs, other pixel formats may be supported. FFmpeg auto-selects the pixel format for the output as not all encoders support all pixel formats. It will select the pixel format which best preserves the source bit depth, chroma ...


2

The alphaextract/alphamerge filters are meant for this. Since your alpha reference is already greyscale, we only need the alphamerge filter ffmpeg -i main.mp4 -i alpha.mp4 -filter_complex [0][1]alphamerge,format=yuva420p -c:v libvpx -auto-alt-ref 0 out.webm


1

ffmpeg v4.0.2 or higher can encode/transcode VP9 in mp4. Commandline (when encoding): ffmpeg -i INPUT.MKV -c:v vp9 OUTPUT.MP4 Commandline (when transcoding (Super fast)): ffmpeg -i INPUT.MKV -c:v copy OUTPUT.MP4


1

FFmpeg, a command-line app, can write VP9 streams in MP4s. Get a static daily/snapshot binary from https://ffmpeg.zeranoe.com/builds/ Basic command is ffmpeg -i in.mov -c:v vp9 out.mov


1

On Linux I use optimizeVideo, which is a wrapper around ffmpeg that automatically detects those settings according to Google's recommendations. The result is a video which quality difference you cannot tell, but usually orders of magnitude smaller.


Only top voted, non community-wiki answers of a minimum length are eligible