www.scantips.com

Menu of the other Photo and Flash pages here

White Balance Correction - Page 2

Two White Balance Controls - Temperature and Tint

Google and Wikipedia can offer more depth about Color Temperature, but the camera manual tells us some assumed values of White Balance, for example, Sunlight 5200°K degrees, and Incandescent around 3000°K degrees, etc. The idea is that if we heat metal enough, it becomes red hot. If we could heat it hotter, it continues to increase in an energy sequence of red, orange, yellow, white, and blue, called "black body" hot temperatures. Incandescent light bulb tungsten filaments are around 3000°K temperature, and the Sun's surface is about 5800°K. So physics adopts these numbers as a way to measure the color of light.

Incandescent WB expects a orange/yellow light, so correction provides an offsetting blue compensation. Shady WB expects a blue sky light, so correction provides a yellow compensation - both corrected to appear as what we perceive as Daylight, or white light (Sun light is a mixture of all colors, we call it white, a hot temperature between yellow and blue).

But there is also a second control in better WB tools. Temperature runs from Blue to Yellow, and Tint runs from Green to Magenta (see the Adobe sliders below). These two match the Lab color space axes. Tint is not a black body temperature, but it is a White Balance variable, or images can be too green or too magenta. Fluorescent light tends to have a moderate green component. We use the sRGB color space for our images (any color consists of three components, Red and Green and Blue), but brightness is device dependent (not an absolute color). So another system is the Lab color space (device independent) with components L, a, b (see Wikipedia for both color spaces). L is Lightness, 0 is black and 100 is white, like an intensity level - a colorless dimension. (A diversion: a photographed 18% card will Not register as L=18%, because our RGB images have gamma in them. So its L will be closer to 46%, which we confuse to be some imaginary reason it ought to be 50%).

The only necessary point here is that we have two sliders for complete color control. Techie details, but in Lab color, the -a to +a axis is the green to magenta axis that we call WB Tint, and the -b to +b axis is the blue to yellow axis that we call Color Temperature. Any color can be represented in this system. So in this way, the White Balance Temperature and Tint sliders represent these Lab color coordinates, a and b. You can see the raw WB tools below offer fixed steps like Daylight or Shade WB (same as cameras do), but also have two sliders for Temperature and Tint. Low values (left end) of Temperature represent yellow light like Incandescent, shown as a blue correction (go that way for more blue to correct yellow). Same for Tint, from Green to Magenta. Correcting color requires both axis.

A neutral color in the RGB system will have equal R G B components, for example RGB(160,160,160) would be a neutral gray (no color tint). In Lab color, a neutral color would have zero a and b components, no color tint.

About Correcting White Balance - It's Important

Clicking the White Balance tool on that known neutral spot says "Computer, I know this spot is neutral color - so make it actually be neutral color", and any color cast is removed. The beauty is that we don't have to know the color of the light. Whatever it is, the computer just makes it be a neutral color (equal red, green, blue components), simply because we said we know this spot is neutral, make it be neutral. Humans are a big help to computers. :)

This white or neutral thing might be many things, maybe a white shirt or dress, a shirt collar or table cloth, or paper or envelope, or a sign or painted bookcase, or picket fence or church steeple. Many these things are in fact trying to appear white. Something white is often present, but its real color should actually be neutral color (no color tint). Not everything is neutral enough to work, some things are off-white, so if it instead causes worst white balance, and many things will, then just cancel out, and try something else. I'm not promising everything works, but the actual White Balance card is as good as guaranteed, and faith is a comforting thing. Adding this known white card to the scene is so easy to prepare for, just set it out there, or have the subject hold it once (the test shot).

Certainly in a fixed studio situation, where you spend time setting up the lights and setting their levels, for Pete's Sake, get an accurate $5 White Balance card, and use it in your first setup pictures. You can carry it in your bag, and use it anywhere - just take a test picture with it included in the same lighting. It makes all the difference, especially in obvious problem areas, and why not for the important work too? For bounce flash, one typical card reading probably works well everywhere in the same room.

For speed, you do need a way to transfer this corrected White Balance value to the other multiple images in same lighting situation, but Adobe Raw software makes this trivial (even for JPG), allows correcting dozens or hundreds of the session images (in the same light) in the same way with one click to do all of them. White Balance doesn't have to be a problem. Except IMO, photo editors (like even Photoshop) offer awkward color tools designed for graphics, but Raw editors offer greatly better tools designed for photographs, designed to do what cameras need. If interested, the next Raw page here offers a 30 minute video showing Adobe Camera Raw, and how it is used, and a lot of it is white balance. Maximize it to full screen.

A look at White Balance in Raw

This section is a continuation of the previous topic (Part 1 page), about clicking on white things in the image to correct WB (below, the white card, the white background paper, and the white cup). This just happens to mention Raw too. Raw has great tools.

Raw file data ignores white balance in the camera. It will be set later, in the Raw software, after we can actually see what it needs. The Raw software offers the same White Balance menu that cameras offer (plus more and better). Raw offers the same menu that the camera offers, but in the camera, it's hopeful wishing. Here, the big difference is that we can see the image first, and watch to see what works, and what doesn't, to actually know what it needs, and we can try different things, and choose what we prefer. This image shows the Adobe Camera Raw (ACR) white balance menu, no mystery there. We can still choose one standard choice, or we can do more, to actually fix the image right. This is what Raw is about, making corrections later after we can see what is actually needed.

Again, all of our light simply varies in color. Incandescent and fluorescent bulbs are available in a wide range of colors, warm white, cool white, daylight white, etc. Bulbs also shift color a bit as they age. Daylight of course includes direct sun, cloudy, shade, sunset, etc. Even flashes vary color with their power level - that is just how flash tubes work. Almost all studio flash units are more red at low power, and speedlights are more blue at low power. Speedlights don't specify a color temperature spec, because their color simply varies with power level. Studio lights shouldn't, but do, which can only apply to some one unspecified setting, maybe full power, but of course they vary with level too.

Flash color temperature varies with flash power level

This is a Nikon SB-800 speedlight. Speedlight color shifts from a little pink at Full power to a little blue at low power. Most studio monolights shift the opposite direction, to pink at low power. So yes, we can set a standard "Flash WB", but we are kidding ourself to imagine the flash is always one color.

Full flash power
Bounce Flash
(Pink flash at Full)
1/64 flash power
Direct Flash
(Bluish flash at 1/64)
Flash WB set in Camera 5400K.

Here "As Shot" in ACR is 5900K


5900K -3 tint

5900K -3 tint
Flash WB set in ACR, 5500K

The point being,
neither is quite correct.


5500K 0 tint

5500K 0 tint

WB corrected with ACR WB eyedropper on white Background paper
4950K -3 tint

5900K -4 tint
WB corrected with ACR WB eyedropper on Porta Brace White Card
5000K -1 tint

6150K -3 tint
WB corrected with ACR WB eyedropper on rear of white Cup
4800K 0 tint

5800K -2 tint

You see the color difference between full and low power, right? Neither is correct, and while some won't care, others will want it fixed, which we have tools to do. This is a D300 with SB-800 hot shoe flash, ISO 200, f/8, 1/250 second. There are only two pictures here, from the same camera and flash, from the same tripod, just at two different flash power levels - Bounce and direct flash, plus copies with different WB processing applied in ACR. Bounce from colored surfaces will affect the color, but this ceiling was not blue, I promise. :) This is the expected result from varied speedlight power level. The first two rows are NOT corrected (Flash WB), the last three rows have corrected WB.

The numbers under the images are the WB correction values performed and reported by Adobe Camera Raw (ACR), Temperature and Tint. A lower K number result is more blue correction of a more red image to be more neutral. There is about 1000K color temperature difference in this same flash at this range between these two power levels. The first row (full flash power) with standard Flash WB shows speedlight full power flash is reddish (f/8 on ten foot ceiling, to force full power), and second row with 1/64 power direct flash is more blue (Full power to Half power is the big change, then speedlight color tapers more slowly). And most studio mono-lights act the opposite, becoming 300K or 400K red at low power (but there are a couple of those are designed to shift like speedlights).

The first image row is Flash WB in camera. The camera does NOT add this WB to the Raw images, but it does affect the small embedded JPG shown on the cameras rear LCD. And the Raw software can apply it from the Exif data. "As Shot" in ACR is that try, but it is Nikon's proprietary format and not precisely close. I am Not faulting Adobe or Nikon, but the camera WB itself IS fairly crude. We have one WB choice for Flash or Incandescent or Daylight, but there are many colors of each of those. Even if we had choices, we have no way to differentiate until we can see the result (the beauty of Raw).

The second row in chart above simply sets Flash WB in ACR (which is the proper place to do it if using Raw). The third row more specifically corrects by just clicking on the White background (22x30 inches, artists supplies from the craft store). The fourth row corrects on the accurate $5 Porta Brace White Balance Card. The fifth row corrects on the white cup itself. So both top and bottom images become the same color, neither are tinted, both are neutral colors of neutral subjects, and both are pretty good. The worse your image WB is, the more you will love this method. Humans do sometimes prefer a small pink warmer tint on skin tones however.

It could not be any easier. With the White Card, we can click on this spot that we know to be neutral, and the software adjusts the image to remove the color cast there to make it be neutral. Neutral means equal RGB components of the color, no color cast, White or Gray or Black can be neutral (non-colored), but white is the easiest and most useful, with the most resolution of color differences. The points I hope to have made here are:

Flash tubes are roughly daylight color, but they can't have any actual white balance specification, because their color varies with power level. The Nikon camera manuals put a footnote on every mention of temperature degrees K, saying "approximate". Color is not linear over a range of degrees K, so the camera is probably working in Mired units anyway (Mired is 1000000/°K, which is more linear). The camera was set to Flash WB above, and ACR interprets its "As Shot" value as 5900K (you surely want to set WB in ACR instead). The temperature K number is not reported in the image file - Exif does not show any K number.

Cameras specify a White Balance Multiplier value (to process pixels). This is Nikon Exif seen with ExifTool:
WB RB Levels :   1.6875 1.15234375 1 1   (example taken from next image below, camera WB was "Flash")
WB GRBG Levels :   256 432 295 256   (same values in another place, Bayer Green Red Blue Green, divide by 256)

You do want to select White Balance in ACR if using ACR (and you can see what you are doing then). The difference is a moot point, even if we had exact numbers, the light is usually some different unknown anyway . White Balance has already been done in JPG files, whatever it was, it's done now, but the Raw software is doing it now, so ACR tries to figure something out. But the point is, ACR has a WB menu too - use it. Someone needs to specify a proper WB. :)

Possibly none of the camera WB menu numbers are "correct", the system cannot know about the flash that was used, or the actual light color. These are just standard guesses, often about correct when all goes perfectly. But it is clear the $5 Porta Brace White Card easily comes out good every time (neutral is always neutral).

Fortunately, we have no use for a precise number right here, we just fix it and forget it. Flash units normally cannot say anything about their own color temperature, because color varies with power level. This picture was also at 1/64 power, and some color shift is expected (red from studio lights, blue from speedlights, if at low power). Anyway, none of this is the issue. No matter what explanation, the only issue is, no matter what, color varies, and we always need to correct whatever color mismatch we discover, to make the result become neutral, or possibly at least our preference of "correct".

ACR has the Select All button which selects all images, or you can just select some of them, but often you can correct many of them at once, with one click. You click the white card in one of them (or click one of the standard WB values, Flash or Cloudy, etc), and this correction is applied to all that are selected, in one click. The white card only has to be in one of them (a test image). This is a really big deal for multiple photos all in the same session lighting, studio or walk-around bounce in the same room.

How White Balance Correction Works

This section is not "how to", it is about "what is WB?", in a practical sense. This picture is from a studio session (fixed lights), so let's naturally assume we are White Card converts.   Next (in 1. below) is another example, Raw straight out of the camera. Nothing is adjusted yet. It is not real bad, but it is a little warm, red (at 5900K). The camera shot it as Flash White Balance, with AlienBees B400 lights (Main light in Large softbox was near 1/8 power level at ISO 200). But it is Raw, so we can simply set White Balance any way we please now. The Raw software provides a drop-down menu to select any regular White Balance value (just like in the camera, shown above). The default was "As Shot" (the value interpreted from camera). In hindsight, it would have been simpler to explain selecting Flash White Balance here, but it often needs a little correction regardless (because Flash WB is one constant value, but flash tubes vary color with power level). The light often just does not quite match the camera setting.

This is a Nikon D300 Raw image in Adobe CS5 Camera Raw software. The only "raw processing" work done was that the Raw file was opened (no edit yet). It could be simply output as a JPG file to look same as here, but so much opportunity exists first. See Why Should I Shoot Raw? for more about ACR.

1.

So White Balance is off a little here (NOT because it says 5900K, but because the card is obviously a bit red, studio flash at about 1/4 power), but the point is, notice the multiple histogram spikes at the right end of the Red, Green, Blue channels. The large spike is obviously the white card, which is major here (large mass of same one color, more pixels than any other bright color here), easily seen, no mistaking it in the histogram. Neutral color is defined as having equal RGB components, but these now are not equal. Red has higher values than blue here. These spikes are the RGB components of this color of this card... but they are not equal RGB components, which neutral white ought to be. And the card is neutral white, so our goal is clear.


So... next (in #2, to demonstrate a point, that White Balance is actually pretty simple to understand), I played like I was the white balance tool. I merely adjusted first the Temperature, and then the Tint sliders, manually, to line up these right end histogram peaks (the white card) of these three curves by eye, to place them at more equal location (and make them be white) in the histogram. This is what white is, and it is what White Balance tools do - balances the channels so that actual neutral colors (white or gray) have equal RGB components. It is of course more accurate when we know this peak is actually something neutral, which was true here. It could have been a gray card with the spikes in the middle, but it needs to be known neutral (and for humans, spikes to identify it). The result is properly less red now. My try came out 5400K Temperature, and -20 Tint. These numbers are relative here, not numerically significant in themselves. Adjustment is made either by clicking on a pure white object, or just for good results by eye, or in this case, we could simply align the white card peaks in the histogram.

2.


Next (in #3 below, to demonstrate the White Balance Tool is very easy to do), I instead just used the regular Raw White Balance tool to simply click the White Balance card (normal routine procedure). The drawn red line below shows selecting the White Balance tool, and where it clicked the white card. It came out 5300K and -18 tint. FWIW, the little red arrow marks a small white space on the dress, and alternately clicking that was very close, about 5350K (but not all white places are this neutral - the zebra stripes up near shoulder were off more, and variable). But there are often opportunities present, and you will likely recognize the correct color when you see it pop out. But it is a real good idea to pay $5 for the card, and know what you have. You gotta see it to appreciate it, but it is real pleasure to see the color pop in correctly, so easily. Remember, this is not even about Raw, we always have to deal with correcting White Balance, but Raw just makes it so easy (wide range, good tools).

The yellow line marks the Color Sampler Tool (not required, nor part of the process, I just wanted to show it). It shows the RGB components of the marked (clicked) spot, both are shown by the yellow line. After the histogram peaks are lined up well by clicking the White Balance tool on the White Card, which adjusted color so that this spot shows R 210, G 210, B 210, which are equal RGB components, i.e., neutral white, no color cast. If it were burnt out bright to 255, 255, 255, it would be worthless then to detect a color cast. Don't overexpose it, and of course, don't overexpose your portrait either. The white card works great, so long as it is actually neutral. Since this card of course happened to actually be neutral white (planned that way), then all is good, the RGB components are equal, and the color is now neutral and correct, same as the actual card. The unadjusted first image showed 219, 210, 210, unequal, and slightly red (same as histogram shows). My manual rough try above showed 210, 210, 208... pretty close, and 1% is about the absolute minimum difference human eyes can detect.

3.


Now suppose... what if in #4, this picture out of the camera accidentally used incandescent white balance? - Giving it a heavy blue cast, since the promised orange incandescent light was not actually present (created here with 2900K White Balance, same result as if camera did it). It really doesn't matter, since it is Raw, we can still set it any way we wish now. Flash White Balance here and now would have been fairly close, like if the camera had done it - not perfect, but in the ballpark, it was flash after all. But see the three widely spaced channel peaks? That's the color of the supposedly white card. Blue channel is strong, red is weak, not even close to equal. But no problem at all, Raw makes it easy - either just select the Flash White Balance menu to get as close as the camera could have done it, or just click the White Card to be precise.

4.

The point here was to do an extreme correction shift, to show what White Balance correction does. The little animated GIF here shows the histogram as the temperature slider moves up warmer (from 2900K to 5300K), shifting the channels; the blue channel moved down to be lower, darker, and the red channel moved up to be higher, brighter. It is an extreme shift, but Green does not shift as much. The three peaks are the RGB components of the white card (neutral color when equal, no color cast). Clicking the white card would do this more simply, but here, the known white histogram peaks were manually aligned (which does the same thing).

Watch carefully at left as the Temperature slider moves from 2900K (blue image) to 5300K (neutral), and then the Tint slider moves from -3 to -18 to clean it a bit more. It simply shifts the blue and red channels independently until this white peak has equal channel positions (equal RGB components). It can do this because we know the white card is neutral, and bright, and large to cause the recognizable peaks, and we know white is equal RGB components. The White Balance tools today make the three RGB components of the clicked spot be equal, which is done by shifting the channels. It is the SAME final result as #3 just above, 5300K and -18 tint.

Histogram height is relative, it always auto-scales the height to fill the height, and the height jumping around might be confusing until we learn to ignore it. We don't care about a "count", everything is relative. Histograms just always try to fill most of the full height, so we can see it better. As the tones are shifted here, the tall clipped peaks (red at zero, blue at 255) come down, giving space to increase overall height of the rest, so it does, automatically. Absolute height is not important in histograms, it is all relative, and the data is always scaled to try to approach full height. The result white point (exposure) could be moved to slide the data to the right a little, but portrait skin tones are often better if you don't push it so close.

This channel shifting is what White Balance does. This extreme case shown would be a drastic shift for JPG. The camera does this while still 12-bit data, before output to JPG. And Raw software does this while still 12-bit data, before output to JPG. JPG is only 8 bits per RGB channel, however smaller changes can still work OK.


Menu of the other Photo and Flash pages here

Continued - Why Choose Raw Processing?


Copyright © 2012-2016 by Wayne Fulton - All rights are reserved.

Previous Menu Next