Color theory is a body of practical guidance to color mixing and the visual effects of specific color combination
Questions tagged [color-theory]
39 questions
26
votes
9 answers
Color Theory: How to convert Munsell HVC to RGB/HSB/HSL
I'm looking at at document that describes the standard colors used in dentistry to describe the color of a tooth. They quote hue, value, chroma values, and indicate they are from the 1905 Munsell description of color:
The system of colour notation
…
![](../../users/profiles/12597.webp)
Ian Boyd
- 220,884
- 228
- 805
- 1,125
10
votes
1 answer
Does the .Net Color struct use an HSB or HSL colour space?
As I understand it HSL and HSB colour spaces are very similar, both use the same 0-360 colour wheel for hue and the same 0-1 value for saturation. The one difference between them is that in the HSB model you have brightness, where 0 is black and 1…
![](../../users/profiles/905.webp)
Keith
- 133,927
- 68
- 273
- 391
9
votes
1 answer
Given a finite palette, how to sort from Hot to Cold, i.e. Diverging
Update (Original question below)
Issue is partially solved.
Still trying to figure out how to extend to other color combinations
If I use this code
hLIM <- rgb2hsv(col2rgb('#8000ff'))['h', ]
sLIM <- rgb2hsv(col2rgb('#8000ff'))['s', ]
vLIM <-…
![](../../users/profiles/9829762.webp)
Artie Ladie
- 451
- 2
- 11
6
votes
6 answers
Converting RGB to RGBW
I know this has already been asked, but the anwser given there doesn't work. I've spent over an hour looking for a formula or algorithm, but have found nothing. As a result, I've started writing my own algorithm to convert RGB to RGBW in the most…
![](../../users/profiles/2950509.webp)
user2950509
- 902
- 1
- 13
- 30
6
votes
3 answers
Converting an RGBW color to a standard RGB/HSB representation
I am building an interface for light management in a home automation system. I managed to control standard on/off and dimmable light for various providers with little problem, but now I am stuck with a problem related to RGB light.
The light I am…
![](../../users/profiles/1005187.webp)
SPArcheon
- 1,129
- 15
- 30
5
votes
1 answer
How to programmatically arrange a set of 256 RGB colors in 2D so that there all adjacent colours have a smooth transition
I have a set of 256 colors (all available colors in an xterm-256color terminal) and I am using a script called 256colors2.pl that I see mentioned in nearly every Internet article that talks about 256 color terminals. This is script's output is a…
![](../../users/profiles/116957.webp)
Jacobo de Vera
- 1,641
- 1
- 14
- 17
5
votes
2 answers
Programming a simple color scheme generator
we are developing a website cms in C# and want to integrate / develop a small and simple color scheme generator as like as colorschemedesigner.com (of course simplier) to automatically suggest harmonizing template colors (for body background, text,…
![](../../users/profiles/562717.webp)
MrHardware
- 53
- 1
- 5
4
votes
1 answer
Algorithm to find which two colors mix to form a third color (in JavaScript)
I am looking for a library/algorithm/technique to take the 3 additive or subtractive colors and determine what combination of two results in some color x.
This is not a correct example (as I don't know much about color theory yet), but this is to…
![](../../users/profiles/169992.webp)
Lance Pollard
- 66,757
- 77
- 237
- 416
3
votes
1 answer
What color space does MSPaint use? (Window 7)
What color space does MSPaint use? (I believe all MSPaints are same for last several versions, but it just to make sure, I am Windows 7).
It would appear that it is HSL, however, the Lum goes from 0 to 240, but from what I read, on HSL Lum should go…
![](../../users/profiles/753997.webp)
judeclarke
- 1,126
- 4
- 15
- 30
3
votes
1 answer
Color that is most contrast to a given set of colors?
I have a list of several different "random" colors values (no less than 1 and no more than 8 colors). (Random means that there is no telling of their mutual "contrast".)
Colors are given as RGB values (possible simplification: as H values in HSL…
![](../../users/profiles/6236.webp)
Alexander Gladysh
- 34,198
- 31
- 94
- 153
3
votes
1 answer
Best Practice for Sorting Distinct Hex Colors in R
Update: Based on answers, I am researching ColorBrewer and Colorspace R packages. Due to request, I am re-writing my original question.
Question: How to best sort individual, predefined hex colors so that similar colors are grouped together, yet…
![](../../users/profiles/9829762.webp)
Artie Ladie
- 451
- 2
- 11
3
votes
1 answer
How to implement the vivid light color blend in code?
I am trying to implement the vivid light color blend in code (I guess c# for now). I found two pages that say how to do it, but I don't understand their…
![](../../users/profiles/1497454.webp)
omega
- 30,811
- 68
- 188
- 388
2
votes
1 answer
Mathematical Calculation for Colorfulness of Image (Color Theory)
I recently tested the following algorithm for determining the "colorfulness" of an image by David Haslera and Sabine Susstrunk, which is implemented in Python here. However, I noticed something interesting about the performance of this algorithm on…
![](../../users/profiles/9476628.webp)
jippyjoe4
- 742
- 4
- 19
2
votes
1 answer
How to tell if a color is imaginary/impossible?
Short version
How can I tell if a color (e.g. XYZ) is impossible? (Wikipedia: Imposible color)
For example, this color is impossible:
XYZ: (15.96, 84.04, 0)
xyY: (0.1595, 0.8404, 0.8404)
Lab: (93, -196, 161) (D65 whitepoint)
It's impossible…
![](../../users/profiles/12597.webp)
Ian Boyd
- 220,884
- 228
- 805
- 1,125
2
votes
1 answer
Mapping polar coordinates to a color (RGB, etc.)
Say I have 80 (or n) polar coordinates that are pretty evenly distributed across a circular area. I want a unique color for each polar coordinate.
If you imagine a color wheel like this (though it could be a different transformation if you like),…
![](../../users/profiles/1002098.webp)
delrocco
- 453
- 3
- 23