Compiling libvpx with row-mt multi-threading on Windows

Compiling

  • choco install msys2 -y or get it here
  • C:\tools\msys64\msys2_shell.cmd
  • pacman -S gcc mingw-w64-x86_64-winpthreads-git mingw-w64-x86_64-libwinpthread-git binutils coreutils yasm git base-devel p7zip
  • git clone https://chromium.googlesource.com/webm/libvpx && cd libvpx
  • ./configure --target=x86_64-win64-gcc --disable-docs && make -j16
  • 7z a libvpx-git-win64.7z *.exe /usr/bin/msys-2.0.dll /usr/bin/msys-gcc_s-seh-1.dll /usr/bin/msys-stdc++-6.dll

tip (to compile newer builds)

  • make clean && git pull

Encoding

  • ./ffmpeg.exe -i source.mkv -pix_fmt yuv420p workfile.y4m
  • ./vpxenc.exe -w 1280 -h 720 --row-mt=1 --tile-columns=6 --auto-alt-ref=1 --lag-in-frames=25 --aq-mode=0 --threads=16 --target-bitrate=3000 --cpu-used=0 -o test.webm workfile.y4m

Notes:

Currently, the improved MT encoder works in 1-pass/2-pass good quality mode encoding at speed 0, 1, 2, 3 and 4 and row-mt=1 must be enabled

Finally my Ryzen 1700X can show its prowess, it now uses ~80% instead of 25% lol

Download:
https://awesome.nwgat.ninja/misc/libvpx-1.6.1-510-gc53020-git-win64.7z

sources: https://groups.google.com/a/webmproject.org/forum/#!topic/codec-devel/oiHjgEdii2U