How to transcode short video using FFmpeg, libx264 codec, Swift, iOS app

34 Views Asked by At

The goal is to transcode a short video into .mov format using FFmpeg and libx264 codec. So far I have not been able to do this using third-party libraries. Using the command line, the video is perfectly transcoded, but I need it inside the application.

If anyone has a solution I would be very grateful.

The resulting video needs to have the following parameters, something like this:

Picture 1 Picture 2 Picture 3

For example:

let command = ["ffmpeg", "-i", videoOutputURL.path, "-c:v", "libx264", "-c:a", "copy", convertedVideoUrl.path]
let ffmpegCommand = ffmpeg(command)
0

There are 0 best solutions below