Is there a way to use Javascript to reduce a animated GIF ?