Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/soulcutter/husler
A ruby implementation of HUSL, a human-friendly color space
https://github.com/soulcutter/husler
Last synced: 3 months ago
JSON representation
A ruby implementation of HUSL, a human-friendly color space
- Host: GitHub
- URL: https://github.com/soulcutter/husler
- Owner: soulcutter
- License: other
- Created: 2012-10-07T02:52:42.000Z (over 12 years ago)
- Default Branch: master
- Last Pushed: 2012-11-19T23:16:41.000Z (about 12 years ago)
- Last Synced: 2024-10-06T03:17:13.995Z (3 months ago)
- Language: Ruby
- Size: 246 KB
- Stars: 9
- Watchers: 3
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# Husler [![Build Status](https://secure.travis-ci.org/soulcutter/husler.png)](http://travis-ci.org/soulcutter/husler)
A ruby implementation of [HUSL, a human-friendly color space](http://boronine.com/husl/).
## Usage
```ruby
Husler.rgb_to_husl(r, g, b) # rgb values must be between 0 and 1Husler.husl_to_rgb(h, s, l) # h(ue) is between 0-360 and s(aturation) and l(ightness) between 0-100
```## Credit
Algorithms translated from Alexei Boronine's canonical implementation at https://github.com/boronine/husl