Reducing the size of animated GIFsThere's no getting away from the fact that animated GIFs are large. They're basically a set of multiple GIFs in one file. If you don't take steps to minimized their size, then you could be sending unnecessarily large files across the Internet. Fortunately, there are a number of ways of keeping the size down:
Even 22.4K could be considered too large, and you can push the size even smaller with a little work. As you can see, the animation actually only needs to re-draw certain parts of the GIF between frames - the word 'GIF' never needs to be re-drawn. GIFs with large blocks of color compress well, and the same goes for GIFs with large areas of transparency. In the original animated GIF, none of the frames were transparent, since each frame needed to overwrite the frame beneath it. However, by using transparency and only masking off those areas of the frame that change, the size of the individual GIFs can be brought down even further. In the extreme case of the first few frames, where nothing changes so that there's a delay before the animation starts, a set of completely transparent compact 2-bit GIFs can be used.
The screenshot above shows the Xara Webster file used to create the final animated GIF, with the background colored white to show the grey mask (obviously the grey background was reinstated for saving the bitmaps, or the edges of the shapes would have anti-aliased to white). By this trick alone, the GIF size was brought down to 15.6K.
Did this page help you? If not, please email us to tell us why not so we can improve it.
|