farg 0.4.5

A Rust library for colorimetry, color space conversions, and color manipulation.
Documentation
use crate::{
  illuminant::{Illuminant, IlluminantType},
  spectral::Spd,
};

static SPD_DATA: [(u32, f64); 97] = [
  (300, 0.00),
  (305, 0.00),
  (310, 0.00),
  (315, 0.00),
  (320, 0.01),
  (325, 0.20),
  (330, 0.40),
  (335, 1.55),
  (340, 2.70),
  (345, 4.85),
  (350, 7.00),
  (355, 9.95),
  (360, 12.90),
  (365, 17.20),
  (370, 21.40),
  (375, 27.50),
  (380, 33.00),
  (385, 39.92),
  (390, 47.40),
  (395, 55.17),
  (400, 63.30),
  (405, 71.81),
  (410, 80.60),
  (415, 89.53),
  (420, 98.10),
  (425, 105.80),
  (430, 112.40),
  (435, 117.75),
  (440, 121.50),
  (445, 123.45),
  (450, 124.00),
  (455, 123.60),
  (460, 123.10),
  (465, 123.30),
  (470, 123.80),
  (475, 124.09),
  (480, 123.90),
  (485, 122.92),
  (490, 120.70),
  (495, 116.90),
  (500, 112.10),
  (505, 106.98),
  (510, 102.30),
  (515, 98.81),
  (520, 96.90),
  (525, 96.78),
  (530, 98.00),
  (535, 99.94),
  (540, 102.10),
  (545, 103.95),
  (550, 105.20),
  (555, 105.67),
  (560, 105.30),
  (565, 104.11),
  (570, 102.30),
  (575, 100.15),
  (580, 97.80),
  (585, 95.43),
  (590, 93.20),
  (595, 91.22),
  (600, 89.70),
  (605, 88.83),
  (610, 88.40),
  (615, 88.19),
  (620, 88.10),
  (625, 88.06),
  (630, 88.00),
  (635, 87.86),
  (640, 87.80),
  (645, 87.99),
  (650, 88.20),
  (655, 88.20),
  (660, 87.90),
  (665, 87.22),
  (670, 86.30),
  (675, 85.30),
  (680, 84.00),
  (685, 82.21),
  (690, 80.20),
  (695, 78.24),
  (700, 76.30),
  (705, 74.36),
  (710, 72.40),
  (715, 70.40),
  (720, 68.30),
  (725, 66.30),
  (730, 64.40),
  (735, 62.80),
  (740, 61.50),
  (745, 60.20),
  (750, 59.20),
  (755, 58.50),
  (760, 58.10),
  (765, 58.00),
  (770, 58.20),
  (775, 58.50),
  (780, 59.10),
];

impl Illuminant {
  pub const C: Self = Self::new("C", IlluminantType::Daylight, Spd::new(&SPD_DATA));
}