#color #pixel #rgb #lab

lab

Tools for converting RGB colors to the CIE-Lab* color space, and comparing differences in color

10 releases (5 breaking)

0.6.0 Sep 30, 2018
0.5.0 Sep 25, 2018
0.4.4 Sep 19, 2018
0.4.3 Jun 1, 2018
0.1.0 Jan 29, 2017

#30 in Images

Download history 21/week @ 2018-10-23 13/week @ 2018-10-30 105/week @ 2018-11-06 31/week @ 2018-11-13 38/week @ 2018-11-20 27/week @ 2018-11-27 58/week @ 2018-12-04 14/week @ 2018-12-11 21/week @ 2018-12-18 43/week @ 2018-12-25 11/week @ 2019-01-01 20/week @ 2019-01-08 12/week @ 2019-01-15

160 downloads per month
Used in 3 crates

MIT license

11KB
212 lines

Rust library for converting RGB colors to the CIE-L*a*b* color space

extern crate lab;
use lab::Lab;

let pink_in_lab = Lab::from_rgb(&[253, 120, 138]);
// Lab { l: 66.639084, a: 52.251457, b: 14.860654 }
extern crate lab;
extern crate image;

use lab::Lab;
use image::Rgba;

let pixel: Rgba<u8> = Rgba { data: [253, 120, 138, 255] };
let lab = Lab::from_rgba(&pixel.data);
// Lab { l: 66.639084, a: 52.251457, b: 14.860654 }

lib.rs:

Lab

Tools for converting RGB colors to L*a*b* measurements.

No runtime deps