Jump to content

How to use Emby's ffmpeg?


Recommended Posts

Posted

I have a script that converts DVR recordings, marks commercials, converts subtitles, etc. and in the past tried to use the same command lines that Emby uses via what is shown in the logs since i'm not an ffmpeg expert. Over the last two months or so I started using hardware acceleration and it looks like the ffmpeg Emby is using has custom changes to it and I'd like to be able to leverage that version. If I call it directly I get library errors and I seem to recall that you need to setup environment variables or "something" to be able to use it. Anyone have any idea? Thanks!

Posted

It won't be easy due to environment variables and such. We can try to document this when we have a chance.

Posted

Thanks, Luke. If it's a 'hackish' process then don't worry about it as I'd rather keeps things clean.

Soggybottoms
Posted (edited)

I have a script that converts DVR recordings, marks commercials, converts subtitles, etc. and in the past tried to use the same command lines that Emby uses via what is shown in the logs since i'm not an ffmpeg expert. Over the last two months or so I started using hardware acceleration and it looks like the ffmpeg Emby is using has custom changes to it and I'd like to be able to leverage that version. If I call it directly I get library errors and I seem to recall that you need to setup environment variables or "something" to be able to use it. Anyone have any idea? Thanks!

 

Hi,

 

These are the library paths I use to get Emby's custom ffmpeg to work for me. Running on Ubuntu 16.04.6 (still on server version 4.0.2.0)

 

export LD_LIBRARY_PATH=/opt/emby-server/lib:/opt/emby-server/lib/samba

 

Good luck!

Edited by Soggybottoms
  • Like 1
Posted

Thank you, I'm gong to try this out!

  • 2 weeks later...
Posted

So I tried the exports and couldn't get it to work. I'm using hardware acceleration and got a library error for vaapi. 

Soggybottoms
Posted

So I tried the exports and couldn't get it to work. I'm using hardware acceleration and got a library error for vaapi. 

 

What shared library file is it requesting? There are a couple of directories that also have shared library files under /opt/emby-server/lib that Emby's custom ffmpeg may be requesting to get it to allow you to use vaapi hw acceleration.

 

You can run the ldd command on Emby's custom ffmpeg binary to see all the shared library dependencies, but it might be best just to trial and error your ffmpeg statement from your script and add whichever path is needed to your export statement until it works without error.

 

In my post processing script I'm also calling hw acceleration when using Emby's custom ffmpeg, but I have a P400 (nvidia) so the above exports I posted were all I needed to get it to work.

 

Good luck!

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...