Is it possible to take a remote (but I can download it first if needed) GIF sequence and make a MPMoviePlayerViewController playable mp4 on the device?
I have tried using http://api.online-convert.com/, but the API doesn't suit and the free version is too restricted for our needs.
Imagemagick for iOS also doesn't seem to include GIF support.
Can I convert a GIF into a video? Yes, this converter tool quickly and easily transforms GIFs into MP4 video files. Additionally, this convert to MP4 tool is powered by Adobe Premiere, which provides you with professional quality results in seconds.
Whichever Android version you are using, download open Convertio app on your phone browser. Step 1: Search for GIF - Download and save GIF files on your Android phone. Step 2: Set output video format – Click the downward arrow on the MP4 and a drop-down menu will pop up.
Launch VLC. Click on the Media menu, and choose the Convert / Save option from the menu. Go to the File window, click on + Add to select the GIFs you want to convert from your device.
This wasn't so easy. There is a gist snippet here with the solution.
Swift 3.0 version.
https://gist.github.com/powhu/00acd9d34fa8d61d2ddf5652f19cafcf
Usage
let data = try! Data(contentsOf: Bundle.main.url(forResource: "gif", withExtension: "gif")!)
let tempUrl = URL(fileURLWithPath:NSTemporaryDirectory()).appendingPathComponent("temp.mp4")
GIF2MP4(data: data)?.convertAndExport(to: tempUrl, completion: { })
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With