Histogram Choices in Photoshop

The basic function of the histogram is not hard to understand. It plots the tonal range of an image in a graph, going from pure black on the left to pure white on the right. The numerical data of the image is always shown in 8-bit form. In other words, the graph always shows 256 tonal levels even if the image has more (e.g. 16-bit with 65,536 levels). For the sake of consistency and practicality, this makes sense.

Histograms become more confusing when you bump into their various forms. Look at the drop-down menu in Photoshop CC and you’ll see six histogram choices. These are: RGB, red, green, blue, luminosity and colors. Perhaps a histogram refresher course wouldn’t go amiss.

The RGB Histogram

The RGB histogram unifies all three of the red, green, and blue histograms. That means it gives the sum total of all three RGB values at every one of its 256 levels. This is useful in that it shows you when colour is being “clipped” (i.e. badly exposed causing loss of detail).

What the RGB histogram doesn’t do is show you which colours are being clipped.  That means it can’t give you vital information about exposure and luminance. All three channels must be clipped before highlights are blown or shadows blocked. In the screenshot above, you can see there is clipping to the left of the graph, but you’ve no way of telling whether it reflects one, two or three colours. There is a lack of nuance.

Red, Green and Blue Histograms

In case you hadn’t guessed it, red, green and blue histograms represent separate RGB colours: the primary colours of light. The good thing about viewing these channels discretely is that you can clearly see which colour channels are being clipped. Clipping can cause smooth tonal transitions to appear as harsh, unnatural “banding”.

If there is enough data in one or two channels, it’s possible to recover highlight or shadow detail even when a single channel is clipped. Note there is a distinction between luminance clipping, which causes complete loss of shadow or highlight detail, and saturation clipping, which loses detail in only one colour channel.

Red flowers as a subject are especially prone to saturation clipping. When that happens, you’ll end up with red blobs rather than anything horticultural. The luminosity histogram on the back of many old or cheap cameras would not warn you of this. You’d need either an RGB histogram or, better still, the separate red, green and blue histograms.

When viewed as a group, red, green and blue histograms give an indication of colour casts. Theoretically neutral areas of an image, such as white or grey clouds, would peak in the same place if the overall hue (or white balance) was unbiased.

All pixels in a black and white RGB image have the same red, green, and blue values (between 0 and 255). This means all histograms look the same when you have a black and white image open.

The Luminosity Histogram

The luminosity histogram focuses on overall exposure, so it tells you when all three RGB channels are clipped but won’t tell you when they’re clipped individually. At least it won’t do so very clearly. It effectively treats all images as if they were black and white.

Notably, the luminosity histogram is weighted to take human perception of brightness into account. Thus, green, being the brightest perceived colour, has a 59% weighting while red gets 30% and blue 11%. Any pixel containing pure red, green or blue data will register at a corresponding place along the graph. For instance, a green pixel with 0,255,0 RGB values would appear just over half way.

Only when pixels contain all three colours at their brighter, more saturated values does the data creep towards the right-hand side of the histogram. Eventually, when all three RGB values are at “255”, the pixel is pure white and contains no detail. Conversely, any area with 0,0,0 values is pure black, and again no detail can be retrieved.

When your intended photographic subject contains a single colour, the luminosity histogram has obvious shortcomings. You might notice a spike at a particular point along the graph to indicate clipping, but it’d be hard to decipher its exact meaning.

luminosity histogram, histograms, brightness, luminance histogram
This illustrates the positions of pure red, green and blue pixels on a luminosity histogram. From left to right it shows blue (RGB 0,0,255) at 11%, red (RGB 255,0,0) at 30% and green (RGB 0,255,0) at 59%.
The Colors Histogram

Aside from being a useful choice in Photoshop, the colors histogram appears in Lightroom. It shows all the individual red, green and blue channels together, so you can see exactly which, if any, are being clipped.

Areas containing all three primary colours appear as grey in the colors histogram. Thus, if highlights were completely blown you’d see grey banked up to the right of the graph. If only one colour is overexposed, you’ll see that colour banked up to the right, and so on.

If you see cyan, magenta or yellow in the colors histogram, you know that the corresponding area is absent of red, green or blue, respectively. Cyan represents a mixture of green and blue, magenta is red and blue, and yellow is red and green.

By creating an artificial image of pure red, blue and green, the colors histogram is duped into flagging up luminance clipping (i.e. as if the image contained an area of pure white). Unlike the luminosity histogram, it doesn’t weight colour channels according to their perceived brightness. However, it does offer the most complete data for editing.
Which to Use?

If you have only one histogram open, the colors histogram offers the most info and is surely the best choice.

Should you have room in your Photoshop workspace, the “All Channels View” shows all three RGB channels separately plus the histogram of your choice on top. The weighted luminosity histogram might be useful in that set-up, since it provides alternative data.

Lightroom’s Tint Slider and the Planckian Locus

In Lightroom’s develop module, the top two sliders are the colour temperature slider (“temp”) and the tint slider. Most of us are familiar with colour temperature: the higher the number along the Kelvin scale, the cooler or bluer the light looks. The scale is back to front in Lightroom so that the higher numbers along the axis represent yellow and lower numbers blue. Perhaps this is because we are often correcting colour temperature rather than observing it.

The second slider is the tint slider. This follows a green to magenta axis, which is less intuitive than blue to yellow. We know that daylight varies in colour. It ranges from a warm, yellow hue in early morning or evening sunlight to a bluer colour during the middle of the day. Natural light follows a path akin to that of the Lightroom temp slider. So, what is the tint slider for?

Look at the diagram below. It shows the Planckian locus, which defines the path of colour temperature. The locus is orange at 1500K and gradually turns yellow then blue. Light sources created by heat follow this path or, in the case of daylight, one next to it (the daylight locus). The lines you see crossing the locus represent “correlated colour temperatures”. Note their green to magenta axis at the 6000K daylight mark.

Planckian locus, correlated colour temperature, fluorescent lighting, LED lighting, Kelvin scale, colour temperature, color temperature, tint slider
The Planckian locus represents the Kelvin scale, whereas the lines crossing it are “correlated colour temperatures”. (Image: Wikipedia)

Fluorescent and LED light sources never have a “true” colour temperature. Instead, they have a correlated colour temperature. They are prone to marked variation in hue along a green to magenta axis. If you’ve ever seen a green or magenta colour cast when trying to calibrate a monitor, this is because of fluorescent or LED backlighting. Filament lighting is more consistent in hue and always sits on a precise point along the Planckian locus.

daylight locus, natural light, colour temperature, color temperature, tint slider
The daylight locus plots the chromacities (colour qualities) of daylight through its different phases. It’s represented here by the upper curve, with the Planckian locus below it. In LED or fluorescent lighting, chromacities such as D50 and D65 are inherently more precise than correlated colour temperatures. Image by Adoniscik GFDL or CC BY-SA 4.0-3.0-2.5-2.0-1.0]

Now we can see a potential use for the Lightroom tint slider: artificial lighting. There are other situations where it might be handy. Light reflected off grass creates a green tint in nearby objects, for instance.

The “White Balance Selector” in Lightroom evens up RGB values, thereby removing any colour cast. It affects all the RGB colour channels discussed in the previous blog entry. Thus, it alters both the temp and tint sliders (blue to yellow, magenta to green).

Pulling Histograms Apart

There are various types of histogram in photography, including RGB, luminosity and “colors”. Lightroom uses the latter, since it shows which RGB colours are being clipped and to what extent. “Clipping” is underexposure or overexposure. It shows as data banking to the left or right of the histogram. If all three red, green and blue channels clip in unison, the tone is either pure black or white and no detail is retrievable.

In Photoshop CC and on many camera LCDs, you have the choice of viewing discrete RGB histograms. This makes it easy to see colours being clipped*, since the data is not packed into one small graph. It’s also useful for assessing colour balance, because peaks in the three histograms align when the colour is neutral. Photos with a strong colour cast or bias yield uneven histograms.

Primary and Secondary Colours

To help you understand separate RGB histograms, it’s handy to know that they each represent a range of colours. For instance, a fully saturated red will cause data to bank over to the right of the red histogram. If the data was to bank to the left it’d indicate the opposite: pure cyan. Cyan is the secondary colour that opposes red on an RGB colour wheel. Thus, you can think of these histograms as cyan to red, magenta to green and yellow to blue.

RGB histograms, red histogram, green histogram, blue histogram, color, colour balance, colour editing
Though not shown this way, individual RGB histograms represent the three primary colours and their secondary opposites.

When making levels adjustments in Photoshop using the separate RGB channels, moving the left or middle slider to the right increases the secondary colour. Equally, moving the right or middle slider left strengthens the primary colour. You wouldn’t usually make these edits unless getting rid of a colour cast. Similarly, in a curves adjustment, pulling the red, green, or blue curve down boosts the secondary colour.

*If shooting raw files, the camera’s histogram does not depict exposure latitude as precisely, since it’s derived from a JPEG.