Commit graph

4 commits

Author SHA1 Message Date
Daniel Thwaites
ba5565d698
Refactor palette generator ♻️
Simplified a lot of code which was unnecessarily generic.

Now using monads to manage the state of the random number generator
rather than passing it around by hand.

Also made some performance improvements, then increased the population
size so more combinations are tried in a similar length of time.
2023-07-08 14:28:15 +01:00
Daniel Thwaites
671068f7f6
Add internal docs for palette generator 💡
So that I don't forget how it works :)
2022-05-02 01:12:27 +01:00
Daniel Thwaites
c2358177dc
Use an external library for base16 ♻️
https://github.com/SenchoPens/base16.nix
2022-04-23 10:36:20 +01:00
Daniel Thwaites
09892b21a5
Use a genetic algorithm to choose colours
This produces much more visually pleasing palettes compared to the crude
algorithm which was previously used.
2021-12-16 20:03:07 +00:00