Hey UC,
I would like to request implementing Wolt’s BlurHash for allowing rendering of small blurry thumps:
BlurHash is a compact representation of a placeholder for an image.
Should be fairly simple to implement and the encoder is implemented in most languages.
I would suggest either as a return result from the Upload API, or via the URL API from a something like https://ucarecdn.com/id/blurhash
Personally I would prefer it as a return from the upload API, as it can be easily stored besides the UC image url (Leaving the hash to be next to my image path)
Hi @ns1, thanks for the suggestion! We’ll look into this. So far, you might want to try using the /blur/ operation to generate similar placeholders. For example:
Original https://ucarecdn.com/7ce000da-ab38-498d-9d0f-22a1c7b3f0f8/-/resize/256x/
Placeholder https://ucarecdn.com/7ce000da-ab38-498d-9d0f-22a1c7b3f0f8/-/resize/256x/-/blur/200/ (2.4 KB)
But the cooler thing about blur-hash is that it can be stored as a compact string in the database, therefore the thump is synchronously being rendered before the image is requested.
Hey @Alex, we’re currently implementing this feature in our App to show the blurhash-images until the actual image is loaded.
Quick question: I know we can get the blurhash via the -/json/ operation, but in fact it would actually be way more convenient for us if we can get the hash in the file-uploader response so we can save it immediately and do not have to make an additional request. The OutputFileEntry already includes a fileInfo (UploadcareFile) with an ImageInfo. This seems to be quite similar to the original object in the -/json response.
Would it be possible to include the blurhash there or does it need always need to be applied to an image processing option?
Of course the question would be is the blurhash for the original image or for the image with applied modifiers
Hey @hannes, thanks for the feedback! We do plan to integrate this feature more deeply into the system, including adding a blurhash field to the fileInfo object. However, we can’t provide an ETA just yet, as there are some improvements needed to the upload API to make this possible. We’ll keep you updated and share news as soon as we have it!