executeWithArguments method

Future<int> executeWithArguments(
  1. List? arguments
)

Executes FFmpeg synchronously with commandArguments provided. This method returns when execution completes.

Returns zero on successful execution, 255 on user cancel and non-zero on error.

Implementation

Future<int> executeWithArguments(List<dynamic>? arguments) async {
  try {
    final Map<dynamic, dynamic> result = await _methodChannel
        .invokeMethod('executeFFmpegWithArguments', {'arguments': arguments});
    return result['rc'];
  } on PlatformException catch (e, stack) {
    print("Plugin executeWithArguments error: ${e.message}");
    return Future.error("executeWithArguments failed.", stack);
  }
}