3 ms·
In addition to being limited to max. 256 colour palettes and 1-bit alpha (encoded as a palette entry), they only support run-length encoding (Edit: NOT! it's ac
by microcolonel 9y ago
In addition to being limited to max. 256 colour palettes and 1-bit alpha (encoded as a palette entry), they only support run-length encoding (Edit: NOT! it's actually LZW) for compression. The combination of RLE (Edit: NOT! It's actually LZW, same point somewhat valid) and dithering (used to overcome the palette colour limitation) results in typical compression ratios which are worse than nothing.
Personally I think a hybrid between a video codec (h.264, VP10, etc.) and a lossless transparent still codec (PNG) would be a good way to go
- mcbits 9y agoGIFs use LZW compression, which is the part that was patented. I think the main problem is that the dithering necessary to make 256 colors look good introduces a lot of high-frequency noise, making the compression less effective.
- microcolonel 9y agoOh boy, I don't know how I got the impression that it was RLE. Maybe I was mixing it up with older versions of Targa. Yeah, the noise was more the point I was getting at. IIRC PNG also has the benefit of prefilters which allow it to (and maybe there are other things) compress rectangles as contiguous symbols rather than splitting them across lines, which makes obvious sense for 2D images.