4 ms·
Not sure why I would want to use this instead of progressive image decoding with a (CSS?) blur filter. Instead of a blurred image suddenly flashing to a fully l
by z33k 4y ago
Not sure why I would want to use this instead of progressive image decoding with a (CSS?) blur filter. Instead of a blurred image suddenly flashing to a fully loaded image, the user would see the image quality gradually improve as it loads over the network.
Then again, progressive JPEG or FLIF is not supported that well anywhere, so I guess this could be the best thing right now because it seems to just require HTML5 canvas.
- crimsonnoodle58 4y agoA blurhash is much easier to send along with the JSON data used to display the initial page. To see a blurred version of a progressive JPEG the browser must have first started to download that JPEG. When there are many JPEG's to download, it may not even have started downloading yet.
- divan 4y agoI typically store it in the DB along with the image ID (or URL). It's being displayed even before network request to the actual image has started. Works like a charm on slow networks.
- zulu-inuoe 4y agoStore what? The BlurHash ?
- divan 4y agoCorrect. It's just 20-30 bytes of data.
- sirn 4y agoMastodon, for example, use it to defer loading of images tagged with Content Warning until the user clicked reveal. It provides a useful context for user to decide whether to view the image, while not require browsers/clients to load the image beforehand.