radiobrowser-api-rust icon indicating copy to clipboard operation
radiobrowser-api-rust copied to clipboard

Provide blurhash string for favicon

Open onny opened this issue 4 years ago • 2 comments

Hey, I'm currently rewriting my Radio app for Nextcloud which is using your great API. I noticed that favicons have different loading times in the station list. It depends on their size and sever speeds on the other side. Would it be possible to return a short blurhash string in the json api response of the favicon? Maybe behind an optional request parameter. You might already know https://blurha.sh . This is how it would look like for a favicon:

20201022_22h02m03s_grim

Note the wrong image aspect ratio in the example above. It might look even better ;) Blurhash images would look great as a placeholder before the actual image is loaded!

Best regards Jonas

onny avatar Oct 22 '20 20:10 onny

i understand that this would add the dependency to an external service.

segler-alex avatar Nov 17 '20 22:11 segler-alex

It is possible to calculate the hashes in rust, see https://github.com/Raincal/blurhash-rs

onny avatar Nov 19 '20 09:11 onny