Batch resize creates animated gif
Posted: 2012-04-02T13:07:06-07:00
I'm using the following command to resize all images in a directory to multiple sizes. If one of the images in the directory happens to be a gif the output is an animated gif. Any tips on how to prevent this? Preferably without needing to do multiple executions. Looking at the commands and flags work it seems like it would be hard to parse that an animated gif should not be created
Code: Select all
convert /somedir/*.* +clone -resize 1000x1000 -set filename:f 'resized/%t_1000.%e' -write '%[filename:f]' +delete +clone -resize 600x600 -set filename:f 'resized/%t_600.%e' -write '%[filename:f]' +delete +clone -resize 320x320 -set filename:f 'resized/%t_320.%e' -write '%[filename:f]' +delete -resize 80x80 -set filename:f 'resized/%t_80.%e' '%[filename:f]'