-
Notifications
You must be signed in to change notification settings - Fork 5
Setting up ffmpeg
Setting up ffmpeg
for Minema is very important! ffmpeg
is a command-line (CLI) media utility that offers kajillion bajillion (basically endless possibility) features to work with media files and different codecs, i.e. images, video and audio. You can crop, trim, add text labels, apply effects, compress, downscale and do many more operations with videos.
Minema uses ffmpeg
to encode captured frames into video files. Writing code that allows to read or write mp4 video files is very very complicated, so ffmpeg
makes it very easy (at a cost of extra dependency)!
There is a video tutorial on how to configure ffmpeg
, but it's pretty old.
First, download ffmpeg
from one of those links:
- For Windows: https://www.gyan.dev/ffmpeg/builds/
- For Linux and macOS: https://www.ffmpeg.org/download.html
There was a problem in the past, that Windows build websites were gone, so if the Windows link doesn't work anymore, go to the second link instead and choose Windows build there.
Linux and macOS builds should be straightforward to download (for macOS Download as ZIP), but for Windows, if gyan.dev page is still up, make sure to download one of the release builds. You should download the one that is called ffmpeg-release-full.7z
. You'll probably need WinRaR to unzip it.
Before you configure Minema to make it work with downloaded ffmpeg
, you first need to test whether ffmpeg works. If you're on:
- Linux, you know what to do 😉, just run
ffmpeg
in terminal. - macOS, open
Terminal.app
(you can either look it up in Spotlight, 🔎 icon in top right corner, or go to Finder, press Command + Shift + U, and findTerminal.app
there), drag downloadedffmpeg
(which should be inbin/
folder) file into the window, and press enter - Windows, open
cmd.exe
(either by pressing Window + R, and typing incmd.exe
and enter, or by pressing Window key, and in the search typing inCommand Prompt
and clicking it), drag downloadedffmpeg.exe
which is in unzippedbin/
folder, and press enter.
If you done everything correctly, the terminal/command prompt should display something close to this:
If it works, proceed to the next step. If it says something like permission denied, the possible cause of the issue is that your account has limited permissions, which I guess requires an administration access (so your account is restricted). If it says something else altogether, then you did something wrong. Double check the instruction again.
Once ffmpeg
is downloaded and checked for permission to run, if you're on:
- Windows, move
ffmpeg
's folder to root of the disk, likeC:\ffmpeg\
orD:\ffmpeg\
, whatever disk you're using. - macOS, move
ffmpeg
file to documents or any place you won't lose it.
Then, in Minecraft, go to Minema's mod options, which can be opened by pressing Shift + F4 in world, and then click Mod options...
button. Click Encoding
and specify the full path to ffmpeg.exe
or ffmpeg
file. In my case, it's C:\ffmpeg-4.4.1-full_build\bin\ffmpeg.exe
, for macOS it would be something like /Users/YOUR_USER/Documents/ffmpeg
, and for Linux it should be just ffmpeg
. You may also want to create a folder for where all the video files will be written to, by going to Capturing
category, and specifying the Capturing Path to your desired folder like C:\movies\
or /Users/YOUR_USER/Movies/
(make sure that the folder was created first).
Press Done
button multiple times (or the that change won't be saved) until you get back to the first menu, and now you can exit with Escape key.
Now try recording by pressing F4. Wait a couple of seconds, press F4 again to stop recording, and check the video that was created in the capturing folder. If it plays fine (you may want to use VLC video player), then you're done!
If there were any error messages in the chat, the most possible causes is that either the Capturing and Encoder Paths don't find the folder/ffmpeg
by those paths, or your account doesn't have enough permissions to operate with it. Double check this page, maybe you skipped some step, and maybe also see the old tutorial video.
Hopefully, that was helpful!