|
|
7 년 전 | |
|---|---|---|
| android | 7 년 전 | |
| example | 7 년 전 | |
| ios | 7 년 전 | |
| lib | 7 년 전 | |
| packages | 7 년 전 | |
| tool | 7 년 전 | |
| .gitignore | 7 년 전 | |
| .metadata | 7 년 전 | |
| CHANGELOG.md | 7 년 전 | |
| LICENSE | 7 년 전 | |
| LICENSE.GPLv3 | 7 년 전 | |
| README.md | 7 년 전 | |
| flutter_ffmpeg.iml | 7 년 전 | |
| pubspec.yaml | 7 년 전 |
FFmpeg plugin for Flutter. Supports iOS and Android.
Supports
v4.2-dev-x (master) releasesarm-v7a, arm-v7a-neon, arm64-v8a, x86 and x86_64 architectures on Androidarmv7, armv7s, arm64, arm64e, i386 and x86_64 architectures on IOS24 external libraries
fontconfig, freetype, fribidi, gmp, gnutls, kvazaar, lame, libaom, libass, libiconv, libilbc, libtheora, libvorbis, libvpx, libwebp, libxml2, opencore-amr, opus, shine, snappy, soxr, speex, twolame, wavpack
4 external libraries with GPL license
vid.stab, x264, x265, xvidcore
zlib and MediaCodec Android system libraries
bzip2, zlib IOS system libraries and AudioToolbox, CoreImage, VideoToolbox, AVFoundation IOS system frameworks
Licensed under LGPL 3.0, can be customized to support GPL v3.0
Includes eight different packages with different external libraries enabled in FFmpeg
| min | min-gpl | https | https-gpl | audio | video | full | full-gpl | |
|---|---|---|---|---|---|---|---|---|
| external libraries | - | vid.stab x264 x265 xvidcore |
gmp gnutls |
gmp gnutls vid.stab x264 x265 xvidcore |
lame libilbc libvorbis opencore-amr opus shine soxr speex twolame wavpack |
fontconfig freetype fribidi kvazaar libaom libass libiconv libtheora libvpx libwebp snappy |
fontconfig freetype fribidi gmp gnutls kvazaar lame libaom libass libiconv libilbc libtheora libvorbis libvpx libwebp libxml2 opencore-amr opus shine snappy soxr speex twolame wavpack |
fontconfig freetype fribidi gmp gnutls kvazaar lame libaom libass libiconv libilbc libtheora libvorbis libvpx libwebp libxml2 opencore-amr opus shine snappy soxr speex twolame vid.stab wavpack x264 x265 xvidcore |
| android system libraries | zlib MediaCodec |
|||||||
| ios system libraries | zlib AudioToolbox AVFoundation CoreImage VideoToolbox bzip2 |
|||||||
Add flutter_ffmpeg as a dependency in your pubspec.yaml file.
Default installation of FlutterFFmpeg enables the default package, which is based on https package. It is possible
to enable other installed packages using the following steps.
```
```
Execute commands.
import 'package:flutter_ffmpeg/flutter_ffmpeg.dart';
final FlutterFFmpeg _flutterFFmpeg = new FlutterFFmpeg();
_flutterFFmpeg.execute("-i file1.mp4 -c:v mpeg4 file2.mp4").then((rc) => print("FFmpeg process exited with rc $rc"));
Check execution output.
_flutterFFmpeg.getLastReturnCode().then((rc) => print("Last rc: $rc"));
_flutterFFmpeg.getLastCommandOutput().then((output) => print("Last command output: $output"));
Stop an ongoing operation.
_flutterFFmpeg.cancel();
Get media information for a file.
_flutterFFmpeg.getMediaInformation('<file path or uri>').then((info) => print(info));
List enabled external libraries.
_flutterFFmpeg.getExternalLibraries().then((packageList) {
packageList.forEach((value) => print("External library: $value"));
});
Enable log callback.
void logCallback(int level, String message) {
print(message);
}
...
_flutterFFmpeg.enableLogCallback(this.logCallback);
Enable statistics callback.
void statisticsCallback(int time, int size, double bitrate, double speed, int videoFrameNumber, double videoQuality, double videoFps) {
print("Statistics: time: $time, size: $size, bitrate: $bitrate, speed: $speed, videoFrameNumber: $videoFrameNumber, videoQuality: $videoQuality, videoFps: $videoFps");
}
...
_flutterFFmpeg.enableStatisticsCallback(this.statisticsCallback);
Get last received statistics.
_flutterFFmpeg.getLastReceivedStatistics().then((stats) => print(stats));
Set log level.
_flutterFFmpeg.setLogLevel(LogLevel.AV_LOG_WARNING);
Register custom fonts directory.
_flutterFFmpeg.setFontDirectory("<folder with fonts>");
0.1.0 releases is based on FFmpeg v4.2-dev and MobileFFmpeg v4.2.LTSRefer to Changelog for updates.
This project is licensed under the LGPL v3.0. However, if installation is customized to use a package with -gpl postfix (min-gpl, https-gpl, full-gpl) then FlutterFFmpeg is subject to the GPL v3.0 license.
Digital assets used in test applications are published in the public domain.
Feel free to submit issues or pull requests.