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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// Copyright 2025 Gabriel Bjørnager Jensen.
//
// This Source Code Form is subject to the terms of
// the Mozilla Public License, v. 2.0. If a copy of
// the MPL was not distributed with this file, you
// can obtain one at:
// <https://mozilla.org/MPL/2.0/>.
/// Denotes a type suitable for use as a colour component.
///
/// Note that not all components types are necessarily transformable; most colour spaces and formats require some form of floating- or fixed-point arithmetic for transformations to be at least be somewhat accurate.
/// Only the most basic of colours spaces can thus be translated using simple integers.
///
/// Also note that some colour types may be preprogrammed for specific components and are thus not generic or only generic for a specific subset of components types.
/// Usually, this trait is only useful for types that implement [`BalancedColour`](crate::BalancedColour).
///
/// # Safety
///
/// Implementors of this type may not contain any padding.
///
/// Additionally, the component must also have a bit state for denoting `0` (zero), and this state must only contain null bits.
pub unsafe
=> ;
}
impl_component!