2 releases
Uses old Rust 2015
0.1.1 | Jan 11, 2016 |
---|---|
0.1.0 | Sep 25, 2015 |
#4 in #represents
631 downloads per month
Used in 17 crates
(10 directly)
10KB
125 lines
HSL
Note: Unmaintained -- contact @killercup if you want to have the name on crates.io!
Represent colors in HSL and convert between HSL and RGB.
License
Licensed under either of
- Apache License, Version 2.0, (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.
lib.rs
:
Represent colors in HSL and convert between HSL and RGB.
Examples
use hsl::HSL;
let yellow = [255, 255, 0];
let yellow_hsl = HSL::from_rgb(&yellow);
assert_eq!(yellow_hsl, HSL { h: 60_f64, s: 1_f64, l: 0.5_f64 });
Dependencies
~145KB