Tuesday, August 19, 2008

A Little About Color: RBG vs. HSV

Most everyone who's worked in any media for screen would (and should) be aware of the importance of the RGB value system. While it is a concise system for describing colours, it is somewhat difficult for us to describe the nature of a colour by amounts of each channel by eye. So rather than describing the additive blend of colours, we can describe a colour with HSV which breaks colour down into more simplistic characteristics. Let's look at each of these in detail:

RBG
Defined by listing how much red, green, and blue is contained in a single value. Being additive, the more of each colour that is added, the brighter (and closer to white) it becomes:

While it's helpful to denote how much of each colour exists, it is not a very friendly system to describe a hue shift, saturation, or value/brightness). Try looking at a colour and try to arbitrarily dictate how much of each primary colour composes it. Not so easy right?

HSV
A colour system that describes a hue shift, saturation, and value is known as HSV:

Now that's a lot easier to describe colour with. Want a colour to be more turquoise? Scarlet? Plum? Just shift the hue slider until it hits the sweet spot. Need brightening without losing saturation? It does that too!

Natural Brightness
With colours having different natural brightnesses to each other, preserving luminosity when tinting with hue shifts poses a problem with contrast. When adjusting a saturation value in HSV, the value scale adjusts proportionately to maintain the same amount of brightness.

For example, take a look at the following diagram:

Yellow has a higher natural brightness than purple which sits on the opposite end of the colour spectrum (which is easily observed when looking at it in grey scale). What does this mean? It means that simply lightening or hue shifts destroy levels of saturation when controlling all channels. This is because the natural luminosity of red, green and blue at equal saturations differ significantly. To compensate the desaturation, the value/brightness needs to be scaled in HSV to match. It is important to maintain a strong contrast in brightnesses, so attention to natural brightness is helpful in picking appealing colour schemes and palettes.

Wrapping It Up
While amounts in HSV are not completely relevant for telling a display how much within each RGB channel is required, it creates a scale that describes useful properties of colour. And at the end of the day, it's returned as RGB or hexadecimal; merely a different way to break down colour components into locations within a given colour gamut.

The next time you are exploring your favourite image editor, make sure to check out the different colour slider modes:

Of course HSV doesn't scale to all digital colour spaces, but in most cases you should be able to flip over from the RGB scale. Being able to apply traditional approaches in picking and applying colour opens up a more fluid and natural work flow, which can assist the transition for traditional artists migrating into the digital realm. So HSV or RGB as a colour refining scale? Obviously HSV! Get into the habit of tweaking colour with the HSV sliders, and you will be able to control those all too often fidgety selectors and pickers in a breeze!