5 ms·
FLIF only has a lossless mode. For lossless animation, it usually beats GIF, APNG, MNG, WebP and BPG. It is the only responsive animation format afaik. For los
by jonsneyers 11y ago
FLIF only has a lossless mode. For lossless animation, it usually beats GIF, APNG, MNG, WebP and BPG. It is the only responsive animation format afaik.
For lossy movies, actual video codecs are best, since they're designed for that. BPG is essentially HEVC (a great but patent-encumbered video codec) so it should be good at lossy movies -- it will be worse on line-art animations with hard edges like e.g. cartoons, or animations with transparency.
- nightcracker 11y agoI don't think this is entirely fair. The full encoding of FLIF is lossless, yes, but it has VERY strong progressive decoding. You could just truncate the file at x% and get lossy encoding that way.
- jonsneyers 11y agoThanks for the compliment about FLIF's progressive decoding! (FLIF author speaking here) However, truncated FLIF files will (probably) never achieve the same quality/size ratio as dedicated lossy methods that can produce a completely different file for each quality setting. So at the moment I still see an important use case for lossy methods. However, in the future, I can imagine that people will start to demand/expect lossless encoding, to avoid generation loss and to get the most out of their display hardware. E.g. higher bit depths are becoming a thing, while the JPEG/WebP color space (YCbCr) is effectively less than 22 bits per pixel (roughly speaking, red and blue are only 7-bit), and chroma subsampling makes this even worse. Also what's the use of ever higher display resolutions if most of those pixels are only displaying compression artifacts or blur? Lossy formats like JPEG/WebP/BPG/JP2/JXR are good at medium-quality, but if you use them at a near-lossless quality setting (e.g. 99 or 100 for JPEG), they often produce bigger files than lossless formats. Meanwhile, the range of display sizes is getting larger: while in the past, we had a range from say 13" monitors to 21" monitors, now we have a range from 1.5" smart watches to huge 100" smart TVs. I do think that in order to avoid huge amounts of rescaling/transcoding, we need image/video formats that are "responsive by design", like JPEG2000 and FLIF (and progressive JPEG to some extent).
- nightcracker 11y agoAs a fun side project I was thinking of writing a clean room FLIF en/decoder, but I can't seem to find any paper or real explanation of the mechanics. Are those coming, or did I just miss those?
- jonsneyers 11y agoThere is a paper draft at https://github.com/FLIF-hub/FLIF-doc https://github.com/FLIF-hub/FLIF-doc, but most of the details still have to be written down (i.e. they're only in the code). Writing out the detailed spec is going to take some effort.
- joveian 11y agoGood luck, it sounds like a great format! One really nice thing about lossless formats is that they are great for archival purposes since you can easily convert them to whatever format is currently optimal or convenient for end use (if you don't want to use it directly). I shudder at the number of complex video implementations that may need to be supported forever due to quality loss if you convert them.