1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
mod luma;
use white_point::{D65, WhitePoint};
use encoding::{Gamma, Linear, Srgb, TransferFn};
pub use self::luma::{Luma, Lumaa};
pub type SrgbLuma<T = f32> = Luma<Srgb, T>;
pub type SrgbLumaa<T = f32> = Lumaa<Srgb, T>;
pub type LinLuma<Wp = D65, T = f32> = Luma<Linear<Wp>, T>;
pub type LinLumaa<Wp = D65, T = f32> = Lumaa<Linear<Wp>, T>;
pub type GammaLuma<T = f32> = Luma<Gamma<D65>, T>;
pub type GammaLumaa<T = f32> = Lumaa<Gamma<D65>, T>;
pub trait LumaStandard {
type WhitePoint: WhitePoint;
type TransferFn: TransferFn;
}
impl<Wp: WhitePoint, T: TransferFn> LumaStandard for (Wp, T) {
type WhitePoint = Wp;
type TransferFn = T;
}