▲ | pxoe 5 days ago | |||||||
Have to wonder what those 20 MB SVGs were like and whether they could've been optimized as SVG still. Doesn't seem to add up that at "huge" resolution that PNG would be that small either. | ||||||||
▲ | jvanderbot 5 days ago | parent | next [-] | |||||||
PNG keeps a count of sequentially-same color pixels (not really but roughly speaking) instead of keeping pixels themselves. So scaling a monocrome png image means just changing the count entry (very roughly speaking), so it'll be nearly zero cost. What I mean is, if you have a million pixels of the same color (0xDEADBEEF maybe), then PNG will call that 1,000,000 x OxDEADBEEF. So, it scales very nicely for few-color, sparse or "blocky" images. | ||||||||
▲ | Swizec 5 days ago | parent | prev [-] | |||||||
> Doesn't seem to add up that at "huge" resolution that PNG would be that small either. Well maybe not huge huge. Like 1000px wide so they look nice on retina screens. The key is that these images were just 2 contiguous color areas. Black and transparent. PNG is really good for that because the compression algorithm works on the basis of contiguous color areas. | ||||||||
|