Wednesday, October 5, 2011

Why GIF images take really long to load sometimes.

GIF from http://impossibru.wikispaces.com

GIF image files are basically a very short video that are compressed into an image. The reason it sometimes takes long for a GIF file to load is because it is stored as big blocks of colors. So instead of loading like "red pixel, red pixel, red pixel, red pixel, black pixel", it will go "red pixel x4, black pixel". It will load each color as a whole instead of individually. So if a GIF file has a lot of shades of red, it could be "red pixel x50" and it would load all 50 at the same time instead of individually. If a GIF files has lots of files this could take really long to load compared to a cartoon image with big parts of the same color.

No comments:

Post a Comment