How can I convert animated WebP to different formats?

3,104 views
Skip to first unread message

jamma...@gmail.com

unread,
May 6, 2019, 6:21:59 PM5/6/19
to WebP Discussion
I would like to convert an animated WebP to other formats, such as WebM, APNG, or GIF.
However, every tool I've seen so far (`convert`, `ffmpeg`, `webpmux`) either only supports unanimated WebPs or converting *to* WebP.

`webpmux` in particular allows exporting frame by frame (but NOT all frames at once as far as I can tell), so it's probably possible to figure out how to extract all frames and metadata and use that to build a WebM, but that really sounds excessively difficult.
My best guess so far would be that I'd have to manually write a script parsing the webpmux output's frames and durations, export each WebP frame into WebM frames, each frame shown as many times as the duration, then use `ffmpeg` to build a video out of them.
Or alternatively, I'd have to manually write a program using libwebp to decode and re-encode to PNG.

Neither of those options sounds appealing. Is there a better way?

Yannis Guyon

unread,
May 9, 2019, 5:15:47 AM5/9/19
to WebP Discussion
Thanks for your question, here are a few suggestions.

GIMP reads WebP files since version 2.10 [1], so it can be used to export animations as GIF and probably to other formats through plugins. Frame duration seems to be read but disposal might need tweaking though (replace if not specified).
About CLI options, there is a thread [2] on the subject with the draft of a script, it might be worth it to check it out.
Some online tools [3] claim to convert from animated WebP but the settings might be limited and there could be privacy concerns.

Reply all
Reply to author
Forward
0 new messages