![]() |
FFmpegKit Linux API 6.0
|
#include <FFmpegKit.h>
Static Public Member Functions | |
static std::shared_ptr< ffmpegkit::FFmpegSession > | executeWithArguments (const std::list< std::string > &arguments) |
static std::shared_ptr< ffmpegkit::FFmpegSession > | executeWithArgumentsAsync (const std::list< std::string > &arguments, FFmpegSessionCompleteCallback completeCallback) |
static std::shared_ptr< ffmpegkit::FFmpegSession > | executeWithArgumentsAsync (const std::list< std::string > &arguments, FFmpegSessionCompleteCallback completeCallback, ffmpegkit::LogCallback logCallback, ffmpegkit::StatisticsCallback statisticsCallback) |
static std::shared_ptr< ffmpegkit::FFmpegSession > | execute (const std::string command) |
static std::shared_ptr< ffmpegkit::FFmpegSession > | executeAsync (const std::string command, FFmpegSessionCompleteCallback completeCallback) |
static std::shared_ptr< ffmpegkit::FFmpegSession > | executeAsync (const std::string command, FFmpegSessionCompleteCallback completeCallback, ffmpegkit::LogCallback logCallback, ffmpegkit::StatisticsCallback statisticsCallback) |
static void | cancel () |
static void | cancel (const long sessionId) |
static std::shared_ptr< std::list< std::shared_ptr< ffmpegkit::FFmpegSession > > > | listSessions () |
Main class to run FFmpeg
commands. Supports executing commands both synchronously and asynchronously.
auto session = FFmpegKit::execute:("-i file1.mp4 -c:v libxvid file1.avi"); auto asyncSession = FFmpegKit::executeAsync:("-i file1.mp4 -c:v libxvid file1.avi", [](auto session){ ... });
Provides overloaded execute
methods to define session specific callbacks.
auto asyncSession = FFmpegKit::executeAsync:("-i file1.mp4 -c:v libxvid file1.avi, [](auto session){ ... }, [](auto log){ ... }, [](auto statistics){ ... });
Definition at line 44 of file FFmpegKit.h.
|
static |
Cancels all running sessions.
This method does not wait for termination to complete and returns immediately.
Definition at line 69 of file FFmpegKit.cpp.
|
static |
Cancels the session specified with sessionId
.
This method does not wait for termination to complete and returns immediately.
sessionId | id of the session that will be cancelled |
Definition at line 78 of file FFmpegKit.cpp.
|
static |
Synchronously executes FFmpeg command provided. Space character is used to split command into arguments. You can use single or double quote characters to specify arguments inside your command.
command | FFmpeg command |
Definition at line 51 of file FFmpegKit.cpp.
|
static |
Starts an asynchronous FFmpeg execution for the given command. Space character is used to split the command into arguments. You can use single or double quote characters to specify arguments inside your command.
Note that this method returns immediately and does not wait the execution to complete. You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
command | FFmpeg command |
completeCallback | callback that will be called when the execution has completed |
Definition at line 57 of file FFmpegKit.cpp.
|
static |
Starts an asynchronous FFmpeg execution for the given command. Space character is used to split the command into arguments. You can use single or double quote characters to specify arguments inside your command.
Note that this method returns immediately and does not wait the execution to complete. You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
command | FFmpeg command |
completeCallback | callback that will be called when the execution has completed |
logCallback | callback that will receive logs |
statisticsCallback | callback that will receive statistics |
Definition at line 63 of file FFmpegKit.cpp.
|
static |
Synchronously executes FFmpeg with arguments provided.
arguments | FFmpeg command options/arguments as string list |
Definition at line 33 of file FFmpegKit.cpp.
|
static |
Starts an asynchronous FFmpeg execution with arguments provided.
Note that this method returns immediately and does not wait the execution to complete. You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
arguments | FFmpeg command options/arguments as string list |
completeCallback | callback that will be called when the execution has completed |
Definition at line 39 of file FFmpegKit.cpp.
|
static |
Starts an asynchronous FFmpeg execution with arguments provided.
Note that this method returns immediately and does not wait the execution to complete. You must use an FFmpegSessionCompleteCallback if you want to be notified about the result.
arguments | FFmpeg command options/arguments as string list |
completeCallback | callback that will be called when the execution has completed |
logCallback | callback that will receive logs |
statisticsCallback | callback that will receive statistics |
Definition at line 45 of file FFmpegKit.cpp.
|
static |
Lists all FFmpeg sessions in the session history.
Definition at line 82 of file FFmpegKit.cpp.