Jump to content

homebrew ffmpeg


Tuxedo

Recommended Posts

Tuxedo

The Viblast blog post had an assertion that VP9 encoding wasn't multithreaded. It turns out, that was true up until April and currently is still true with the emby ffmpeg builds for OSX. As of libvpx 1.4.0, VP9 encoding is multithreaded.

 

As a consequence of my job, I keep ffmpeg and all its libraries fairly up-to-date via homebrew (and a launchd task). Homebrew tends to roll out updates within a week of a new release. Initially, I have installed ffmpeg with this:

 

brew install ffmpeg --with-fontconfig --with-freetype --with-libquvi --with-libvidstab --with-libvorbis --with-libvpx --with-openjpeg --with-openssl --with-opus --with-frei0r --with-rtmpdump --with-schroedinger --with-speex --with-theora --with-tools --with-x265 --with-webp --without-xvid --without-qtkit

A couple of those libraries are for other things I do, but I'm not sure how much can be left out and ffmpeg will still work as expected.

 

There's a lag in ffmpeg emby updates for OSX, so this is probably the best way to go for anyone interested in lower CPU use, encoding quality, etc. Younger libraries like libvpx and libx265 see a lot of ongoing activity and are constantly improving, so it's worth it to keep up.

 

Initially, all I did was replace the contents of ~/.config/emby-server/ffmpeg/20150110/ with symbolic links, and that will work fine. Since then I've replaced them with bash scripts so I can override some of the hardcoded options and limit thread usage to something my computer can safely encode with without the fans repeatedly cycling up and down.

 

There are some library differences between the tessus build and what came from homebrew, particularly regarding audio, but libvo-aacenc apparently underperforms compared to the native encoder and I haven't noticed any problems otherwise.

Edited by Tuxedo
Link to comment
Share on other sites

Tuxedo

For static builds, certainly.

 

The ffmpeg release cycle is pretty quick, but I haven't seen them break backwards compatibility in the past few years. You can probably get away with a cron/launchd/schtasks script to check for a new release every day or so and update the repo with them (and/or replace the binaries in Emby.Resources with a document containing the URLs to the various releases).

Edited by Tuxedo
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...