What is FFmpeg?¶
Compiling FFmpeg on Mac with Apple Silicon (requires MacPorts): FFmpeg on Mac with Apple Silicon (M1): https://youtu.be/w. FFmpeg Installation for Mac: Use homebrew — “brew install ffmpeg” Verify FFmpeg installation by running the “ffmpeg” command directly from your terminal. If installation is successful.
Installing FFmpeg for Windows¶
Downloading¶
Installing¶
- Create a new folder on your computer, the recommended location is C:.
- Name the new folder FFmpeg.
- Drag the contents of the bin folder from the archive into the newly created folder.
- Next, start OpenToonz and open the Preferences window with File → Preferences…
- Navigate to the Import/Export category; at the top you will see a box with the text FFmpeg path.
- Insert the path to your FFmpeg folder that you created earlier, if you have used the recommended path, this will be C:FFmpeg:
- Restart OpenToonz.
- Open the Output Settings window with Render → Output Settings…
Installing FFmpeg for Mac¶
Downloading¶
Installing¶
- Open Finder and create a new folder, the Applications/OpenToonz folder is the recommended location.
- Name the new folder FFmpeg.
- Drag the contents of the bin folder from the archive into the newly created folder.
Tip
For macOS 10.15 and later, each executable within the FFmpeg folder needs to be opened before using OpenToonz (this only needs to be done one time, due to security features). In Finder, right-click on each executable (ffmpeg, ffprobe, and etc.) and select OpenWith→Terminal
. Once the Terminal windows have launched successfully, Terminal can be closed.
- Next, start OpenToonz and open the Preferences window with File → Preferences…
- Navigate to the Import/Export category; at the top you will see a box with the text FFmpeg path.
- Insert the path to your FFmpeg folder that you created earlier, if you have used the recommended path, this will be /Applications/OpenToonz/FFmpeg:
- Restart OpenToonz.
- Open the Output Settings window with Render → Output Settings…
Installing FFmpeg for Linux¶
Arch Linux: #pacman-Sextra/ffmpeg
Debian GNU/Linux: #aptinstallffmpeg
Gentoo Linux: #emergemedia-video/ffmpeg
Solus: #eopkginstallffmpeg
Tip
To make it possible to export files in mp4, webm or gif formats, you need to specify the path to FFmpeg installed on your system, usually it is /usr/bin/ffmpeg. Enter command whichffmpeg
in the shell to find out.
- Start OpenToonz and open the Preferences window with File → Preferences…
- Navigate to the Import/Export category; at the top you will see a box with the text FFmpeg path.
- Insert the path /usr/bin.
- Restart OpenToonz.
- Open the Output Settings window with Render → Output Settings…
The FFmpeg project is a fast, accurate multimedia transcoderwhich can be applied in a variety of scenarios on OS X.
If you just want to add a good video transcoder to a toolset thatalready includes Final Cut Pro, Adobe Photoshop, and similar tools,FFmpegX may be your best choice because of its familiarMac-style user interface.
But it's possible that you are interested in using FFmpeg to set up anautomated, web based system to transcode a variety of input videoformats to the Flash video format, which can easily be displayed onthe web.
In this case it will be neccesary to approach FFmpeg on its own termsas a command-line, Linux-centric project. You will need to learn theinstallation techniques commonly used by open source projects, and thestarting point for your work will be running Terminal and workingmostly from the command line. This article will apply thesetechniques in a step-by-step manner to installing a version of FFmpegwhich has most of the features you will need. Some techniques will beused without explanation, so be prepared to do some Googling to fillin the gaps in your knowledge.
Before you can follow these instructions, you must install Apple'sDeveloper Tools.
Prerequisites: LAME
MP3 is the audio codec most often used with Flash video, so you willneed an MP3 encoder. FFmpeg doesn't include one, but it will useLAME, which creates good quality audio files, if youinstall it. Header files will be needed during the compile, so it isnot enough to install a prebuilt binary using a package manager.Instead follow these directions to compile it from source:
Start by creating a working directory:
On a good day you can get the latest source code release of LAME fromSourceforge. The file you want will be namedlame-3.97.tar.gz or something similar.
If that doesn't work, do what I did and get the bleeding edge releasefrom revision control:
If you download the tar file, you need to unpack it as follows (thiscommand is not necessary if you used CVS):
After downloading and unpacking the source or checking it out fromCVS, change to the main directory and then enter the three commandswhich are typically used to build open source projects:
Each command will take a minute or so to complete. You should keep aneye out for any errors which may occur, but installing LAME isgenerally trouble-free.
Optional: FAAC and FAAD
Since Quicktime commonly uses AAC for audio, you may want to encodeand decode that format. Here again FFmpeg doesn't include built-incodecs, but it will use the codecs provided by another open sourceproject if you install them first.
Installing these codecs used to be so difficult that I wouldn't evenhave tried to address it in an introductory article, but recentimprovements mean that you can simply download the latestreleases and follow the instructions they provide, for example:
It's generally a good idea to poke around in the main directory forfiles named INSTALL and README and pay attention to the instructionsthere. Often that's all you need.
Building FFmpeg for Mac OS X Leopard
Recent versions of FFmpeg will compile successfully on versions of OSX as far back as 10.3. Before that OS X used an older version of theC compiler which is no longer compatible with FFmpeg. It's possibleto get an older version of FFmpeg running on OS X 10.2 (read on), butyou may not be satisfied with its capabilities.
If you have a choice it's best to run a recent version of FFmpeg,which means downloading the source code from one of the revisioncontrol systems used by the developers, or getting a nightlysnapshot. Using revision control for something this simple is prettyeasy, and it's a useful technique, so that's what we'll do. Recentversions of Xcode already include Subversion (a newish revisioncontrol tool which really isn't so bad), so we'll use that.
First create a working directory:
The up-to-date version of FFmpeg generally compiles cleanly, and thatis the version you usually will want:
Next, configure and make
The --disable-mmx flag is not required on a PowerPC. If you leave itout on an Intel Mac, you will probably get a compile error, but it'sworth trying since it will provide a speed boost. If you installedthe AAC codecs, add the flags --enable-libfaac and --enable-libfaad.
(According to a discussion on ffmpeg-user The '--arch' flag isrequired under Snow Leopard. Experiment.)
A fallback
When I tested for this article originally, the latest source in theSubversion repository did not compile cleanly. My workaround was touse a known stable revision. In general, FFmpeg is a moving targetand you may encounter new issues that I did not. See the mailinglists for the latest information. Here's how to build FFmpegif you have problems with the latest release
Once again, the --disable-mmx flag is not required on a PowerPC-basedMac. There is nothing special about revision 15624, it's just aversion that happened to compile when this article was revised. IfFFmpeg is not compiling on OS X because of a recent change,subtracting a small amount from the latest revision number willprobably fix the issue. Work your way backwards until you findsomething that works.
Congratulations, you've installed FFmpeg. The next section describesa similar procedure for OS X 10.2, so skip ahead for additionalinformation on running FFmpeg.
Building FFmpeg for Mac OS X 10.2
[Update: the OS X 10.2 procedure results in an ffmpeg binary thatcan decode only some of the video formats listed in the ffmpegdocumentation. In particular, it can't decode Quicktime video. Takethis into account before you go to the trouble of downloading andcompiling it. On the other hand, this is one of the few freealternatives to Macromedia Flash for converting mpeg into Flash video,and you may be able to convert Quicktime to mpeg by other means.]
Start by creating a build directory:
Compiling on OS X 10.2 requires a patch, and it makes sense to patchagainst a known release. So we will download a recent release, whichcan be found by clicking here, and unpack it:
I have modified a patch by Christoph Seibert to compile onMac OS X 10.2 (if it doesn't work on another version of OS X, tryChristoph's patch). Download it by right-clicking here anduncompress it:
Change to the ffmpeg source directory and apply the patch:
(For more information on using patch, see my article on diff andpatch.)
Now build the project:
Some flv examples
FFmpeg is now installed. There are instructions in the doc/directory, but basic commands are quite simple, and you will find thatthey are similar to ImageMagick, if you have used it. To convert anmpeg video to Flash, use: Acrobat xi pro crack.
(The '-ar 22050' flag sets an audio sample rate of 22050 Hz. It isusually necessary to set a sample rate when encoding flv files becausethe MP3 encoder only supports rates of 11025, 22050, and 44100 Hz.)That's the basic idea, but in practical uses you will probably want totake control over more of the quality settings. A more realisticcommand would look like this:
where
'-b 600k' selects a video bitrate of 600 kilobits per second. Thisis a compromise between quality and bandwidth (with older versionsof FFmpeg you would use '-b 600'. Type 'ffmpeg -h' to check whichunits are expected in your version);
'-r 24' selects 24 video frames per second;
'-ar 22050' selects an audio sample rate of 22050 Hz, which issufficient for voice;
'-ab 96k' selects an audio bit rate of 96 kilobits per second; youcould go a little lower for voice-only audio (with older versions ofFFmpeg you would use '-ab 96'. Type 'ffmpeg -h' to check.)
These are the parameters you will adjust most often. Finding theperfect values for your material is a matter of experiment.
Troubleshooting
flv 1.1 metadata
FFmpeg is a moving target, and this issue is resolved in the latestversion of FFmpeg from the Subversion repository. In older versions,however, FFmpeg didn't write the FLV metadata which is required forthe scrubber bar to work in some Flash video players.
If you experience this problem, there is a fix:
First, try upgrading to the latest version of FFmpeg.
If for some reason you can't upgrade, get the FLV MetadataInjector (Windows-only), or FLVTool2 (OS X andLinux) and process your flv files with them. See the links forinstructions.
make build errors
According to the mailing list, FFmpeg is sensitive to the version of'make' you are running and the build will fail in many cases. Recenttesting shows that the current stable version of GNU make (3.81) willwork, but 3.79 and 3.80 will both fail, for different reasons. BSDmake (also distributed with OS X as 'bsdmake') will fail with multipleerrors. If you are having a problem with make, the simple solutionwould be to upgrade Developer Tools.
Alternate download methods
If your version of Xcode doesn't include a Subversion client, refer tothe FFmpeg download page and pick another method to getthe source, for example: Tuxera ntfs for mac 2019 free. download full version.
Ffmpeg For Windows 10
Runtime errors
Some FFmpeg error messages are a little cryptic. Here are a few Ihave encountered:
If you try to decode a video format that FFmpeg does notunderstand, you get the message
Just try again with another format, or recompile FFmpeg to add thecodec you need.
If you build FFmpeg without the --enable-libmp3lame flag and try toencode to Flash video, the audio stream will be silently discarded.Only by encoding to another format that does not require MP3 will youdiscover that this is not the expected behavior. In this case justfollow the instructions in this article to install LAME, if necessary,and recompile FFmpeg with LAME support.
When encoding to MP3, you may receive the message Chinese radio signal fallout 3.
In practice, this means that you should use the -ar flag to set anaudio sample rate of 11025, 22050, or 44100 Hz.
Further reading
Now that you have video in Flash video format, you may be interestedin publishing it on the web. See my Flash Video Howto forcomplete instructions.
Download Ffmpeg For Mac For Audacity
Howard Pritchett publishes an FFmpeg user's guidewhich includes lots of useful information if you're just starting outwith FFmpeg.
Comment on this article and its topic
Copyright © 2006-2008 Stephen Jungels.Written permission is required to repost or reprint this article
How To Install Ffmpeg Windows
Last modified: Tue Feb 22 10:41:16 CST 2011