How many different hues, saturations and values are possible when converting RGB to HSV?

134 Views Asked by At

If we specify a colour in the RGB space, there are $2^{24}$ different colours, as R, G and B are 8 bit numbers.

When a colour is converted to the HSV colour space (find the conversion formulas here for example), how many different values are possible for H, S and V?

Obviously, the total number of colours is equal in both spaces, as the conversion is a bijection. But how is the information distributed over the three dimensions of the HSV space?

1

There are 1 best solutions below

0
On

The answer ist 118920. The 2^24 RGB values result in 118920 different hues, 19821 saturations, and 256 values. The last one is kind of obvious, but the first two were interesting. I wouldn't have expected the difference to be that big.

What is very interesting is the scatter plots of hue, saturation and values of the colours.

scatter plots of hue, saturation a value of RGB colours

It turns out that there are very few distinct hue values for low saturations and values, which makes sense, because hue is not "important" for greys and dark colours.

What I found most astonishing were the patterns in the hue-saturation plot.

Anyway, that was an interesting and fun exercise.