blurhash.cr alternatives and similar shards
Based on the "Algorithms and Data structures" category.
Alternatively, view blurhash.cr alternatives based on common mentions on social networks and blogs.
-
crystalline
A collection of containers & algorithms for the Crystal programming language -
graphlb
graphlb is a crystal library which contains all the graph Data-Structures and Algorithms implemented in crystal-lang. -
markov
⛓ A Crystal library for building Markov Chains and running Markov Processes. -
crystal-linked-list
Simple linked list implementation in Crystal -
text
A collection of phonetic algorithms for Crystal. Including; Porter-Stemmer, Soundex, Metaphone, Double Metaphone & White Similarity -
kd_tree
Crystal implementation of "K-Dimensional Tree" and "N-Nearest Neighbors" -
haversine
Crystal implementation of the Haversine formula to calculate distances between two points given their latitudes and longitudes -
edits.cr
Edit distance algorithms inc. Jaro, Damerau-Levenshtein, and Optimal Alignment -
splay_tree_map
This is a Crystal implementation of a Splay Tree; which is a type of binary search tree that is semi-balanced and that tends to self-optimize so that the most accessed items are the fastest to retrieve. -
Goban
A fast and efficient QR Code/Micro QR Code implementation in pure Crystal -
delimiter_tree
A crystal-lang tree structure that is built using a delimiter. -
murmur3
Crystal implementation of Murmur3 hash algorithm used by Cassandra -
csuuid
This is a small UUID library that implements a chronologically sortable UUID. -
ternary_search_tree
A Crystal implementation of a Ternary Search Tree -
secure-remote-password
Crystal implementation of the Secure Remote Password protocol (SRP-6a) -
primes
Library for testing primality and factoring integers in Crystal -
s2_cells
maps latitude and longitude to S2 Cells https://s2geometry.io/
Build time-series-based applications quickly and at scale.
Do you think we are missing an alternative of blurhash.cr or a related project?
README
blurhash.cr

A pure Crystal implementation of Blurhash. The API is stable, however the hashing function in either direction may not be.
Blurhash is an algorithm written by Dag Ågren for Wolt (woltapp/blurhash) that encodes an image into a short (~20-30 byte) ASCII string. When you decode the string back into an image, you get a gradient of colors that represent the original image. This can be useful for scenarios where you want an image placeholder before loading, or even to censor the contents of an image à la Mastodon.
Currently supports PNG
and JPEG
file types.
Installation
Library
- Add the dependency to your
shard.yml
:
dependencies:
blurhash:
github: Sija/blurhash.cr
- Run
shards install
CLI
- Run
shards build --release
Usage
Library
require "blurhash"
puts Blurhash.encode(
x_components: 4,
y_components: 3,
path: Path["foo.png"]
)
CLI
$ ./bin/blurhash 4 3 foo.png
Contributing
- Fork it (https://github.com/Sija/blurhash.cr/fork)
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create a new Pull Request
Contributors
- Sijawusz Pur Rahnama - creator and maintainer
*Note that all licence references and agreements mentioned in the blurhash.cr README section above
are relevant to that project's source code only.