This commit is contained in:
Miloslav Ciz 2025-05-03 16:21:08 +02:00
parent 46a27e1930
commit 783a41a7cf
18 changed files with 2157 additions and 2060 deletions

View file

@ -56,37 +56,37 @@ Finally let's quickly go over other concepts related to colors. **[Gamma](gamma.
The following is a table of some common colors:
| color name | red |green|blue |cyan|magenta|yellow| hue |chroma|sat.(V)|sat.(L)|value|light.|grayscale| RGB24 |RGB565|RGB332| comment |
| ------------ |-----|-----|-----|----| ----- | ---- |-----| ---- | ----- | ----- |-----|------| ------- |--------|------|------| --------------------------------------------- |
| white | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 1 |`ffffff`|`ffff`| `ff` | all frequencies, complementary to black |
| light gray | 0.75| 0.75| 0.75|0.25| 0.25 | 0.25 | 0 | 0 | 0 | 0 | 0.75| 0.75 | 0.75 |`c0c0c0`|`c618`| `db` | complementary to dark gray |
| gray | 0.5 | 0.5 | 0.5 |0.5 | 0.5 | 0.5 | 0 | 0 | 0 | 0 | 0.5 | 0.5 | 0.5 |`808080`|`8410`| `92` | complementary to self |
| dark gray | 0.25| 0.25| 0.25|0.75| 0.75 | 0.75 | 0 | 0 | 0 | 0 | 0.25| 0.25 | 0.25 |`404040`|`4208`| `49` | complementary to light gray |
| black | 0 | 0 | 0 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |`000000`|`0000`| `00` | lack of light, complementary to white |
| red | 1 | 0 | 0 | 0 | 1 | 1 | 0 | 1 | 1 | 1 | 1 | 0.5 | 0.29 |`ff0000`|`f800`| `e0` | ~685 nm, RGB primary, complementary to cyan |
| orange | 1 | 0.5 | 0 | 0 | 0.5 | 1 | 0.08| 1 | 1 | 1 | 1 | 0.5 | 0.59 |`ff8000`|`fc00`| `f0` | ~605 nm, RGB tertiary, AKA light brown |
| yellow | 1 | 1 | 0 | 0 | 0 | 1 | 0.16| 1 | 1 | 1 | 1 | 0.5 | 0.88 |`ffff00`|`ffe0`| `fc` | ~580 nm, RGB secondary, complementary to blue |
| green | 0 | 1 | 0 | 1 | 0 | 1 | 0.33| 1 | 1 | 1 | 1 | 0.5 | 0.58 |`00ff00`|`07e0`| `1c` | ~532 nm, RGB primary, complementary to pink |
| cyan | 0 | 1 | 1 | 1 | 0 | 0 | 0.5 | 1 | 1 | 1 | 1 | 0.5 | 0.7 |`00ffff`|`07ff`| `1f` | ~512 nm, RGB secondary, complementary to red |
| blue | 0 | 0 | 1 | 1 | 1 | 0 | 0.66| 1 | 1 | 1 | 1 | 0.5 | 0.11 |`0000ff`|`001f`| `03` | ~472 nm, RGB primary, complementary to yellow |
| violet | 0.5 | 0 | 1 | 0.5| 1 | 0 | 0.75| 1 | 1 | 1 | 1 | 0.5 | 0.26 |`8000ff`|`801f`| `83` | ~415 nm, RGB tertiary |
| pink | 1 | 0 | 1 | 0 | 1 | 0 | 0.83| 1 | 1 | 1 | 1 | 0.5 | 0.41 |`ff00ff`|`f81f`| `e3` | RGB secondary, complementary to green |
| light red | 1 | 0.5 | 0.5 | 0 | 0.5 | 0.5 | 0 | 0.5 | 0.5 | 1 | 1 | 0.75 | 0.64 |`ff8080`|`fc10`| `f2` | |
| light orange | 1 | 0.75| 0.5 | 0 | 0.25 | 0.5 | 0.08| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.79 |`ffc040`|`fe10`| `fa` | |
| light yellow | 1 | 1 | 0.5 | 0 | 0 | 0.5 | 0.16| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.94 |`ffff80`|`fff0`| `fe` | |
| light green | 0.5 | 1 | 0.5 | 0.5| 0 | 0.5 | 0.33| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.79 |`80ff80`|`87f0`| `9e` | |
| light cyan | 0.5 | 1 | 1 | 0.5| 0 | 0 | 0.5 | 0.5 | 0.5 | 1 | 1 | 0.75 | 0.85 |`80ffff`|`87ff`| `9f` | |
| light blue | 0.5 | 0.5 | 1 | 0.5| 0.5 | 0 | 0.66| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.55 |`8080ff`|`841f`| `93` | |
| light violet | 0.75| 0.5 | 1 |0.25| 0.5 | 0 | 0.75| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.63 |`c08040`|`c41f`| `d3` | |
| light pink | 1 | 0.5 | 1 | 0 | 0.5 | 0 | 0.83| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.7 |`ff80ff`|`fc1f`| `f3` | |
| dark red | 0.5 | 0 | 0 | 0.5| 1 | 1 | 0 | 0.5 | 1 | 1 | 0.5 | 0.25 | 0.14 |`800000`|`8000`| `80` | |
| brown | 0.5 | 0.25| 0 | 0.5| 0.75 | 1 | 0.08| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.29 |`804000`|`8200`| `88` | AKA dark orange |
| dark yellow | 0.5 | 0.5 | 0 | 0.5| 0.5 | 1 | 0.16| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.44 |`808000`|`8400`| `90` | |
| dark green | 0 | 0.5 | 0 | 1 | 0.5 | 1 | 0.33| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.29 |`008000`|`0400`| `10` | |
| dark cyan | 0 | 0.5 | 0.5 | 1 | 0.5 | 0.5 | 0.5 | 0.5 | 1 | 1 | 0.5 | 0.25 | 0.35 |`008080`|`0410`| `12` | |
| dark blue | 0 | 0 | 0.5 | 1 | 1 | 0.5 | 0.66| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.05 |`000080`|`0010`| `02` | |
| dark violet | 0.25| 0 | 0.5 |0.75| 1 | 0.5 | 0.75| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.13 |`c00080`|`4010`| `42` | |
| dark pink | 0.5 | 0 | 0.5 | 0.5| 1 | 0.5 | 0.83| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.2 |`800080`|`8010`| `82` | |
| color name | red |green|blue |cyan|magenta|yellow| hue |chroma|sat.(V)|sat.(L)|value|light.|grayscale| RGB24 |RGB565|RGB332| comment |
| ------------ |-----|-----|-----|----| ----- | ---- |-----| ---- | ----- | ----- |-----|------| ------- |--------|------|------| ------------------------------------------------------------------------- |
| white | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 1 | 1 | 1 |`ffffff`|`ffff`| `ff` | all frequencies, complementary to black |
| light gray | 0.75| 0.75| 0.75|0.25| 0.25 | 0.25 | 0 | 0 | 0 | 0 | 0.75| 0.75 | 0.75 |`c0c0c0`|`c618`| `db` | complementary to dark gray |
| gray | 0.5 | 0.5 | 0.5 |0.5 | 0.5 | 0.5 | 0 | 0 | 0 | 0 | 0.5 | 0.5 | 0.5 |`808080`|`8410`| `92` | complementary to self |
| dark gray | 0.25| 0.25| 0.25|0.75| 0.75 | 0.75 | 0 | 0 | 0 | 0 | 0.25| 0.25 | 0.25 |`404040`|`4208`| `49` | complementary to light gray |
| black | 0 | 0 | 0 | 1 | 1 | 1 | 0 | 0 | 0 | 0 | 0 | 0 | 0 |`000000`|`0000`| `00` | lack of light, complementary to white |
| red | 1 | 0 | 0 | 0 | 1 | 1 | 0 | 1 | 1 | 1 | 1 | 0.5 | 0.29 |`ff0000`|`f800`| `e0` | ~685 nm, RGB primary, complementary to cyan |
| orange | 1 | 0.5 | 0 | 0 | 0.5 | 1 | 0.08| 1 | 1 | 1 | 1 | 0.5 | 0.59 |`ff8000`|`fc00`| `f0` | ~605 nm, RGB tertiary, AKA light brown |
| yellow | 1 | 1 | 0 | 0 | 0 | 1 | 0.16| 1 | 1 | 1 | 1 | 0.5 | 0.88 |`ffff00`|`ffe0`| `fc` | ~580 nm, RGB secondary, complementary to blue |
| green | 0 | 1 | 0 | 1 | 0 | 1 | 0.33| 1 | 1 | 1 | 1 | 0.5 | 0.58 |`00ff00`|`07e0`| `1c` | ~532 nm, RGB primary, complementary to pink |
| cyan | 0 | 1 | 1 | 1 | 0 | 0 | 0.5 | 1 | 1 | 1 | 1 | 0.5 | 0.7 |`00ffff`|`07ff`| `1f` | ~512 nm, RGB secondary, complementary to red |
| blue | 0 | 0 | 1 | 1 | 1 | 0 | 0.66| 1 | 1 | 1 | 1 | 0.5 | 0.11 |`0000ff`|`001f`| `03` | ~472 nm, RGB primary, complementary to yellow, most favorite in the world |
| violet | 0.5 | 0 | 1 | 0.5| 1 | 0 | 0.75| 1 | 1 | 1 | 1 | 0.5 | 0.26 |`8000ff`|`801f`| `83` | ~415 nm, RGB tertiary |
| pink | 1 | 0 | 1 | 0 | 1 | 0 | 0.83| 1 | 1 | 1 | 1 | 0.5 | 0.41 |`ff00ff`|`f81f`| `e3` | RGB secondary, complementary to green |
| light red | 1 | 0.5 | 0.5 | 0 | 0.5 | 0.5 | 0 | 0.5 | 0.5 | 1 | 1 | 0.75 | 0.64 |`ff8080`|`fc10`| `f2` | |
| light orange | 1 | 0.75| 0.5 | 0 | 0.25 | 0.5 | 0.08| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.79 |`ffc040`|`fe10`| `fa` | |
| light yellow | 1 | 1 | 0.5 | 0 | 0 | 0.5 | 0.16| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.94 |`ffff80`|`fff0`| `fe` | |
| light green | 0.5 | 1 | 0.5 | 0.5| 0 | 0.5 | 0.33| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.79 |`80ff80`|`87f0`| `9e` | |
| light cyan | 0.5 | 1 | 1 | 0.5| 0 | 0 | 0.5 | 0.5 | 0.5 | 1 | 1 | 0.75 | 0.85 |`80ffff`|`87ff`| `9f` | |
| light blue | 0.5 | 0.5 | 1 | 0.5| 0.5 | 0 | 0.66| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.55 |`8080ff`|`841f`| `93` | |
| light violet | 0.75| 0.5 | 1 |0.25| 0.5 | 0 | 0.75| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.63 |`c08040`|`c41f`| `d3` | |
| light pink | 1 | 0.5 | 1 | 0 | 0.5 | 0 | 0.83| 0.5 | 0.5 | 1 | 1 | 0.75 | 0.7 |`ff80ff`|`fc1f`| `f3` | |
| dark red | 0.5 | 0 | 0 | 0.5| 1 | 1 | 0 | 0.5 | 1 | 1 | 0.5 | 0.25 | 0.14 |`800000`|`8000`| `80` | |
| brown | 0.5 | 0.25| 0 | 0.5| 0.75 | 1 | 0.08| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.29 |`804000`|`8200`| `88` | AKA dark orange |
| dark yellow | 0.5 | 0.5 | 0 | 0.5| 0.5 | 1 | 0.16| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.44 |`808000`|`8400`| `90` | |
| dark green | 0 | 0.5 | 0 | 1 | 0.5 | 1 | 0.33| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.29 |`008000`|`0400`| `10` | |
| dark cyan | 0 | 0.5 | 0.5 | 1 | 0.5 | 0.5 | 0.5 | 0.5 | 1 | 1 | 0.5 | 0.25 | 0.35 |`008080`|`0410`| `12` | |
| dark blue | 0 | 0 | 0.5 | 1 | 1 | 0.5 | 0.66| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.05 |`000080`|`0010`| `02` | |
| dark violet | 0.25| 0 | 0.5 |0.75| 1 | 0.5 | 0.75| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.13 |`c00080`|`4010`| `42` | |
| dark pink | 0.5 | 0 | 0.5 | 0.5| 1 | 0.5 | 0.83| 0.5 | 1 | 1 | 0.5 | 0.25 | 0.2 |`800080`|`8010`| `82` | |
## Code And Conversions