Lovely webm I made with ffmpeg.

I made this webm using ffmpeg.

Firstly, I ripped a section of video.

ffmpeg -i starwars.mkv -vcodec copy -acodec copy -ss 00:19:23 -to 00:19:33 out.mkv

Then I did the first pass of two pass encoding.

ffmpeg -i out.mkv -c:v libvpx-vp9 -pass 1 -qmin 0 -qmax 50 -crf 10 -b:v 1M -threads 1 -tile-columns 0 -speed 4 -g 128 -aq-mode 0 -an -sn -f webm /dev/null

Then the second pass.

ffmpeg -i out.mkv -c:v libvpx-vp9 -pass 2 -qmin 0 -qmax 50 -crf 10 -b:v 1M -c:a libopus -b:a 64K -vbr on -threads 1 -tile-columns 0 -speed 0 -auto-alt-ref 1 -lag-in-frames 25 -g 128 -aq-mode 0 -sn -f webm output.webm

This resulted in a very high quality webm file. And it is only 1 megabyte. Good result for such high quality output. I am not sure why the built-in media player for WordPress has a delay when playing the webm file, but if you download the video it will play fine.

No comments have been made. Use this form to start the conversation :)

Leave a Reply