Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Good day everyone! It's my first time trying to do something like this. I tried many things but finally gave up
I have over 200 sprite sheet .png files that I want to convert to animated .gif files (then if possible change extension to .png, not format)
Windows 8.1 and ImageMagick-6.9.2-10-Q16-x64
mogrify does not specify the input image. It takes all images of -format specified in a folder and makes them into the suffix specified at the end. Basically, one output for each input, only. So you cannot make multiple outputs for each input with mogrify. You will have to write a script loop over each image in the folder and use convert to generate the multiple gif files. see http://www.imagemagick.org/Usage/basics/#mogrify
Also note that PNG does not support animation, so if you convert to png, you will get individual images for each frame.
I do not see a difference between your two sets of command?
I advise against just editing the file suffix from gif to png. Image readers may be confused by the png suffix on gif file. In any case it is "bad form" to do so.
fmw42, the difference is in the second line, one using mogrify and the other convert
thanks for that command snibgo!
just personal stuff in discord, a voice and text chatting program, a .gif file is overlayed with the text "GIF" while .png not
and btw
found out this converts all sprite sheets to animated .gif files in seconds
You have to run 3 mogrify commands. You should be able to write a simple loop over each image in the directory and create an animated gif in one convert command.
loop over each image
get filename (without suffix)
convert filename.png -dispose previous -delay 10 -crop 80x80 +repage -loop 0 filename.gif
end loop
I do not use windows, but this would be trivial in unix.