kaarigar 1 Posted October 15, 2022 Is it possible to create animated GIF using FireMonkey? I have a set of images using which I want to create an animated GIF. Can someone point me to any component or a library that generates animated GIF in FireMonkey? Yhanks! Share this post Link to post
Fr0sT.Brutal 900 Posted October 17, 2022 I doubt it. GIF is too old and also infected with proprietary license. Do you really want to create GIF file or just some animation? 1 Share this post Link to post
Paul TOTH 2 Posted October 17, 2022 GIFs are now patent-free https://burnallgifs.org/archives/ 1 Share this post Link to post
kaarigar 1 Posted October 17, 2022 2 hours ago, Fr0sT.Brutal said: I doubt it. GIF is too old and also infected with proprietary license. Do you really want to create GIF file or just some animation? I don't know about the proprietary license for GIF - the web is full of GIFs and now there are open source libraries to create and manage them. I want to save the animation to a file - so I thought animated GIF may be a simplest way of doing so. The movie format MP4 would also do, but I thought that would be computationally more intensive. Basically any format that can play animation is acceptable for my application. Thank you. Share this post Link to post
Fr0sT.Brutal 900 Posted October 17, 2022 I wasn't aware GIF has cured of its license. However it's still outdated. Seems now APNG, MP4 and WEBM rule but whether use them or not depends on whether you can manage to find corresponding Delphi libs. Share this post Link to post
Paul TOTH 2 Posted October 17, 2022 googling for FMX and GIF... https://beyondvelocity.blog/2020/01/09/gif-animation-in-fmx/ the component: http://www.raysoftware.cn/559.html 1 Share this post Link to post
kaarigar 1 Posted October 17, 2022 21 minutes ago, Paul TOTH said: googling for FMX and GIF... https://beyondvelocity.blog/2020/01/09/gif-animation-in-fmx/ the component: http://www.raysoftware.cn/559.html Thanks for pointing this out. It's a GIF reader that supports reading and displaying animated GIF. Perhaps I can see if I can write a GIF writer based on this. Share this post Link to post
Paul TOTH 2 Posted October 17, 2022 oh sorry, you want to create GIF...I use GifCam for that, but if you need to this by code it's a bit complexe because GIF supports only 256 colors per frame Share this post Link to post
Vincent Gsell 11 Posted October 19, 2022 On 10/17/2022 at 5:47 PM, kaarigar said: Thanks for pointing this out. It's a GIF reader that supports reading and displaying animated GIF. Perhaps I can see if I can write a GIF writer based on this. My 2 cents : For Displaying and animating : - https://github.com/TomDannert/GIFImage - Skia4Delphi ! I do not advise you to use http://www.raysoftware.cn/559.html : It unfortunaly not work on all gif, and on recent compiler, it does not pass range checking. Tom Dannert's version (https://github.com/TomDannert/GIFImage ) is a far better start if you want to write a Gif Writer. It is right that, under FMX, full cross platform (linux and mobile included), I do not have direct solution to write GIF. 1 Share this post Link to post
kaarigar 1 Posted October 19, 2022 47 minutes ago, Vincent Gsell said: My 2 cents : For Displaying and animating : - https://github.com/TomDannert/GIFImage - Skia4Delphi ! I do not advise you to use http://www.raysoftware.cn/559.html : It unfortunaly not work on all gif, and on recent compiler, it does not pass range checking. Tom Dannert's version (https://github.com/TomDannert/GIFImage ) is a far better start if you want to write a Gif Writer. It is right that, under FMX, full cross platform (linux and mobile included), I do not have direct solution to write GIF. Hi Vincent, thanks for your response. I will check out the Tom Dannert's version. There are also some other versions in circulation that are based on RaySoftware's and claim to be bug free. However, my interest in is *creating* animated GIF in Firemonkey for all platforms supported. Share this post Link to post
XylemFlow 8 Posted October 21, 2022 (edited) I use the FFVCL component. It allows encoding using FFmpeg to many formats including animated Gif and animated PNG. FMX is supported and platforms Windows, Mac and Android. It's not free though and does require that you include the ffmpeg libraries with your app, which are quite large. The old gifimage code by Anders Melander works on VCL, but not FMX unfortunately. If you're running on Windows only then that may be an option though. http://www.delphiffmpeg.com/ https://docwiki.embarcadero.com/Libraries/Sydney/en/Vcl.Imaging.GIFImg.TGIFImage Edited October 21, 2022 by XylemFlow 1 Share this post Link to post