There are two different ways to animate images: using vector-based images, or using raster-based images. While sometimes it's hard to tell the difference between the two, sometimes it's only glaringly apparent why vector images and animation are preferred. But why?
- Image size. Pixel-by-pixel data is a lot of information to store, and can really start to stack up on high-quality images.
- Image quality on resize. When you resize a raster image, the data doesn't scale well; if you shrink it, you lose pixel data as larger areas merge into smaller ones. If you enlarge it, you end up with a jagged image as single-pixel data has to expand to fill multiple pixels via messy interpolation.
In contrast, vector images can store more colors and shapes in less space while resizing smoothly, because the lines, curves, and fills are just recalculated during scaling to create a more precise image.

