Post

firefox is shipping JXL so i thought i'd take a look at the state of things, at least for my own system i'm using this image since it has all of: large areas of similar color; fine details (the lineart uses a very noisy brush); and an alpha channel (notoriously hard for png). but mostly bc lexy

PNG, WEBP, AVIF, and JXL all preview in kde dolphin no problem. gimp and imagemagick both appear fully capable of reading and writing all of them. so JXL is basically native already. windows users idk what to tell you, maybe in 2050 meanwhile bluesky has of course already trashed the image

PNG: gimp, max compression — 369k (reference size) imagemagick, default — 376k (−2% smaller) imagemagick, -quality 96 or 100 — 369k (0% smaller) optipng, -o9 — 359k (3% smaller)

WebP, all using the "drawing" mode: gimp, lossless — 223k (40% smaller) imagemagick, lossless, max compression — 212k (43% smaller) i'm not sure how to rate lossy compression since it's obviously very subjective, so i guess i will just give my impressions. only tried a couple variations

WebP cont'd: gimp, quality 100% — 110k (70% smaller) exactly identical to "lossless", which is sensible for 100% quality, but then how is it half the size?? gimp, quality 98% — 101k (73% smaller) looks the same at 1:1. slightly smooths the mane, shuffles the lineart noise. minimal savings though

0 reposts11 likes

WebP cont'd: imagemagick, default — 39k (90% smaller) this is of course visibly worse even at 1:1, though it's not nearly as worse as i expected. basically jpegifies areas of high contrast, though the noise is surprisingly well constrained. this is why every website saves as webp lol

AVIF: gimp, lossless, slow — 334k (10% smaller) gimp, 98% quality, slow — 175k (53% smaller) looks the same to me at 4:1 gimp, 50% quality, slow — 38k (90% smaller) pretty much the same as the webp imagemagick default, except the errors are uncannily smooth rather than uncannily noisy

honestly not sure why anyone was excited about AVIF; it seems very comparable to WebP at similar filesizes? also the "slow" encoder is definitely pretty slow, though i didn't time any of these

and finally JXL: apparently these encoding speed names are canonical also rather than a quality scale, there's an acceptable error scale, where 1 is "visually lossless" and higher is lossier. but gimp also has a lossless checkbox so i guess 1 is not actually visually lossless maybe?

"How is it half the size" presumably because it has large blocks of a single color, and listing the size and location of such a block, along with defining that color once, is a lot faster than saying the exact same color repeatedly for every pixel (which is how an uncompressed .bmp does it)