Resize Animated GIFs and Preserve Animation
Resizing images is fairly simple, whether you are resizing images from the command line or in the programming language of your choice, but when it comes to animated GIFs (or other animated image type) things can get hairy, especially when most techniques will simply resize the first frame of your image, while destroying the rest of the animation frames.
Circumventing this is easy (if you have ImageMagick installed) and the resizing is performed with simple commands:
convert big.gif -coalesce coalesce.gif
convert -size 200x100 coalesce.gif -resize 200x10 small.gif
If you want to perform this action in PHP, you’d do something like this:
system("convert big.gif -coalesce coalesce.gif");
system("convert -size 200x100 coalesce.gif -resize 200x10 small.gif");
User’s Note: Resizing animated GIFs this way usually creates a larger file size, even though the dimensions are smaller, this is because during the resize process, the images in each frame are de-optimized.
Source: http://stackoverflow.com/questions/718491/resize-animated-gif-file-without-destroying-animation



