Home

Awesome

FFmpegKit GitHub release Maven Central CocoaPods pub npm

<img src="https://github.com/arthenica/ffmpeg-kit/blob/main/docs/assets/ffmpeg-kit-icon-v9.png" width="240">

FFmpegKit is a collection of tools to use FFmpeg in Android, iOS, Linux, macOS, tvOS, Flutter and React Native applications.

It includes scripts to build FFmpeg native libraries, a wrapper library to run FFmpeg/FFprobe commands in applications and 8 prebuilt binary packages available at Github, Maven Central, CocoaPods, pub and npm.

1. Features

2. Android

See Android to learn more about FFmpegKit for Android.

3. iOS, macOS, tvOS

See Apple to use FFmpegKit on Apple platforms (iOS, macOS, tvOS).

4. Flutter

See Flutter to learn more about FFmpegKit for Flutter.

5. Linux

See Linux to learn more about FFmpegKit for Linux.

6. React Native

See React Native to learn more about FFmpegKit for React Native.

7. Build Scripts

Use android.sh, ios.sh, linux.sh, macos.sh and tvos.sh to build FFmpegKit for each native platform.

All scripts support additional options to enable optional libraries and disable platform architectures. See Building wiki page for the details.

8. FFmpegKit Library

FFmpegKit is a wrapper library that allows you to easily run FFmpeg/FFprobe commands in applications. It provides additional features on top of FFmpeg to enable platform specific resources, control how commands are executed and how the results are handled.

Android library of FFmpegKit has a Java API, Apple libraries (iOS, macOS, tvOS) have an Objective-C API, Flutter library comes with a Dart API, Linux library has a C++ API and React Native library provides a JavaScript API with Typescript definitions, which are identical in terms of features and capabilities.

9. Packages

There are eight different ffmpeg-kit packages distributed on Github, Maven Central, CocoaPods, pub and npm. Below you can see which system libraries and external libraries are enabled in each one of them.

Please remember that some parts of FFmpeg are licensed under the GPL and only GPL licensed ffmpeg-kit packages include them.

<table> <thead> <tr> <th align="center"></th> <th align="center"><sup>min</sup></th> <th align="center"><sup>min-gpl</sup></th> <th align="center"><sup>https</sup></th> <th align="center"><sup>https-gpl</sup></th> <th align="center"><sup>audio</sup></th> <th align="center"><sup>video</sup></th> <th align="center"><sup>full</sup></th> <th align="center"><sup>full-gpl</sup></th> </tr> </thead> <tbody> <tr> <td align="center"><sup>external libraries</sup></td> <td align="center">-</td> <td align="center"><sup>vid.stab</sup><br><sup>x264</sup><br><sup>x265</sup><br><sup>xvidcore</sup></td> <td align="center"><sup>gmp</sup><br><sup>gnutls</sup></td> <td align="center"><sup>gmp</sup><br><sup>gnutls</sup><br><sup>vid.stab</sup><br><sup>x264</sup><br><sup>x265</sup><br><sup>xvidcore</sup></td> <td align="center"><sup>lame</sup><br><sup>libilbc</sup><br><sup>libvorbis</sup><br><sup>opencore-amr</sup><br><sup>opus</sup><br><sup>shine</sup><br><sup>soxr</sup><br><sup>speex</sup><br><sup>twolame</sup><br><sup>vo-amrwbenc</sup></td> <td align="center"><sup>dav1d</sup><br><sup>fontconfig</sup><br><sup>freetype</sup><br><sup>fribidi</sup><br><sup>kvazaar</sup><br><sup>libass</sup><br><sup>libiconv</sup><br><sup>libtheora</sup><br><sup>libvpx</sup><br><sup>libwebp</sup><br><sup>snappy</sup><br><sup>zimg</sup></td> <td align="center"><sup>dav1d</sup><br><sup>fontconfig</sup><br><sup>freetype</sup><br><sup>fribidi</sup><br><sup>gmp</sup><br><sup>gnutls</sup><br><sup>kvazaar</sup><br><sup>lame</sup><br><sup>libass</sup><br><sup>libiconv</sup><br><sup>libilbc</sup><br><sup>libtheora</sup><br><sup>libvorbis</sup><br><sup>libvpx</sup><br><sup>libwebp</sup><br><sup>libxml2</sup><br><sup>opencore-amr</sup><br><sup>opus</sup><br><sup>shine</sup><br><sup>snappy</sup><br><sup>soxr</sup><br><sup>speex</sup><br><sup>twolame</sup><br><sup>vo-amrwbenc</sup><br><sup>zimg</sup></td> <td align="center"><sup>dav1d</sup><br><sup>fontconfig</sup><br><sup>freetype</sup><br><sup>fribidi</sup><br><sup>gmp</sup><br><sup>gnutls</sup><br><sup>kvazaar</sup><br><sup>lame</sup><br><sup>libass</sup><br><sup>libiconv</sup><br><sup>libilbc</sup><br><sup>libtheora</sup><br><sup>libvorbis</sup><br><sup>libvpx</sup><br><sup>libwebp</sup><br><sup>libxml2</sup><br><sup>opencore-amr</sup><br><sup>opus</sup><br><sup>shine</sup><br><sup>snappy</sup><br><sup>soxr</sup><br><sup>speex</sup><br><sup>twolame</sup><br><sup>vid.stab</sup><br><sup>vo-amrwbenc</sup><br><sup>x264</sup><br><sup>x265</sup><br><sup>xvidcore</sup><br><sup>zimg</sup></td> </tr> <tr> <td align="center"><sup>android system libraries</sup></td> <td align="center" colspan=8><sup>zlib</sup><br><sup>MediaCodec</sup></td> </tr> <tr> <td align="center"><sup>ios system libraries</sup></td> <td align="center" colspan=8><sup>bzip2</sup><br><sup>AudioToolbox</sup><br><sup>AVFoundation</sup><br><sup>iconv</sup><br><sup>VideoToolbox</sup><br><sup>zlib</sup></td> </tr> <tr> <tr> <td align="center"><sup>macos system libraries</sup></td> <td align="center" colspan=8><sup>bzip2</sup><br><sup>AudioToolbox</sup><br><sup>AVFoundation</sup><br><sup>Core Image</sup><br><sup>iconv</sup><br><sup>OpenCL</sup><br><sup>OpenGL</sup><br><sup>VideoToolbox</sup><br><sup>zlib</sup></td> </tr> <tr> <td align="center"><sup>tvos system libraries</sup></td> <td align="center" colspan=8><sup>bzip2</sup><br><sup>AudioToolbox</sup><br><sup>iconv</sup><br><sup>VideoToolbox</sup><br><sup>zlib</sup></td> </tr> </tbody> </table>

10. Versions

FFmpegKit binaries generated use the same major and minor version numbers as the upstream FFmpeg project. The third and last number in the version string, if exists, is specific to FFmpegKit. It shows different releases from the same FFmpeg release branch.

dev part in the version string indicates that FFmpeg source code is cloned from the FFmpeg master branch and the exact version number of FFmpeg is obtained using the git describe --tags command.

PlatformsFFmpegKit VersionFFmpeg VersionRelease Date
Flutter6.0.36.0Sep 19, 2023
React Native6.0.26.0Sep 19, 2023
Flutter6.0.26.0Sep 03, 2023
React Native6.0.16.0Sep 03, 2023
Flutter6.0.16.0Sep 03, 2023
React Native6.0.06.0Aug 27, 2023
Flutter6.0.06.0Aug 27, 2023
Android<br>Apple6.06.0Aug 21, 2023
React Native5.1.05.1.2Oct 02, 2022
Flutter5.1.05.1.2Oct 02, 2022
Android<br>Apple5.15.1.2Sep 29, 2022
React Native4.5.24.5-dev-3393May 25, 2022
Flutter4.5.14.5-dev-3393Jan 02, 2022
React Native4.5.14.5-dev-3393Jan 02, 2022
Android4.5.14.5-dev-3393Jan 01, 2022
Apple4.5.14.5-dev-3393Dec 30, 2021
Flutter4.5.04.5-dev-2008Oct 05, 2021
React Native4.5.04.5-dev-2008Oct 01, 2021
Android<br>Apple4.54.5-dev-2008Sep 18, 2021
Android<br>Apple4.44.4-dev-3015Mar 03, 2021

11. LTS Releases

FFmpegKit binaries are published in two release variants: Main Release and LTS Release.

This table shows the differences between two variants.

Main ReleaseLTS Release
Android API Level2416
Android Camera AccessYes-
Android Architecturesarm-v7a-neon<br/>arm64-v8a<br/>x86<br/>x86-64arm-v7a<br/>arm-v7a-neon<br/>arm64-v8a<br/>x86<br/>x86-64
iOS Min SDK12.110
iOS VideoToolboxYes-
iOS AVFoundationYes-
iOS Architecturesarm64<br/>arm64-simulator<br/>arm64-mac-catalyst<br/>x86-64<br/>x86-64-mac-catalystarmv7<br/>arm64<br/>i386<br/>x86-64
iOS Bundle FormatXCFrameworksFrameworks
Mac Catalyst Min Version14.0-
macOS Min SDK10.1510.12
macOS AVFoundationYes-
macOS Architecturesarm64<br/>x86-64x86-64
macOS Bundle FormatXCFrameworksFrameworks
tvOS Min SDK11.010.0
tvOS VideoToolboxYes-
tvOS Architecturesarm64<br/>x86-64<br/>arm64-simulatorarm64<br/>x86-64
tvOS Bundle FormatXCFrameworksFrameworks

12. Documentation

A more detailed documentation is available under Wiki.

13. Test Applications

You can see how FFmpegKit is used inside an application by running test applications created under FFmpegKit Test project.

All applications are identical and supports command execution, video encoding, accessing https urls, encoding audio, burning subtitles, video stabilisation, pipe operations and concurrent command execution.

14. License

FFmpegKit library alone is licensed under the LGPL v3.0.

FFmpegKit bundles (.aar archives, frameworks, xcframeworks), which include both FFmpegKit and FFmpeg libraries, are also licensed under the LGPL v3.0. However, if the source code is built using the optional --enable-gpl flag or prebuilt binaries with -gpl postfix are used, then FFmpegKit bundles become subject to the GPL v3.0. Because, FFmpeg is licensed under the GPL v3.0 in those bundles. And that makes the whole bundle effectively subject to the GPL v3.0.

FFmpegKit build scripts always configure FFmpeg with --enable-version3 option. And never enable non-free libraries. Thus, FFmpeg libraries created by FFmpegKit are licensed under the LGPL v3.0 by default. Only when --enable-gpl is provided they become subject to GPL v3.0. That is how prebuilt binaries with -gpl postfix are compiled.

Refer to Licenses to see the licenses of all libraries. Trademark lists the trademarks used in the FFmpegKit documentation.

15. Patents

It is not clearly explained in their documentation, but it is believed that FFmpeg, kvazaar, x264 and x265 include algorithms which are subject to software patents. If you live in a country where software algorithms are patentable then you'll probably need to pay royalty fees to patent holders. We are not lawyers though, so we recommend that you seek legal advice first. See FFmpeg Patent Mini-FAQ.

openh264 clearly states that it uses patented algorithms. Therefore, if you build ffmpeg-kit with openh264 and distribute that library, then you are subject to pay MPEG LA licensing fees. Refer to OpenH264 FAQ page for the details.

16. Contributing

See our CONTRIBUTING guide.

17. See Also