Skip to content

Latest commit

 

History

History
19 lines (11 loc) · 843 Bytes

README.md

File metadata and controls

19 lines (11 loc) · 843 Bytes

Quick HCT

Quick HCT uses a precomputed tonal map to quickly approximate transformations of RGB colors to a given tonal value. Tone is one of the dimensions of the HCT color space introduced by Material Design 3. A tone value of 100 is equivalent to the idea of light at its maximum and results in white. Every tone value between 0 and 100 expresses the amount of light present in the color.

Example tonal range for RGB color #426915:

Example tonal range for RGB color #715573:

Usage:

r, g, b := quickhct.WithTone(0x42, 0x69, 0x15, 40)

Quick HCT is released by Microbus LLC under the Apache 2.0 license.