Tutorial: Fixing white-balance (blue cast) in Adobe Photoshop

Reef Aquarium & Tank Building Forum

Help Support Reef Aquarium & Tank Building Forum:

Llarian

Well-known member
Joined
Feb 24, 2004
Messages
556
Location
Seattle, WA
Hello all!

I mentioned that I was going to do a thread on fixing white balance problems, so here it is.
This version is for Adobe Photoshop, using the curves tool. I'll also be posting a version for Photoshop Elements using the levels tool.
The Elements version can also be used in Photoshop, but I reccomend learning the curves tool if yoou have it available, its far more powerful and allows you to be more selective in color and contrast manipulation.

Nikki was kind enough to give me a macro of some mushrooms she took that's in focus, but somewhat washed out due to the white balance being off, so I'm using that as an example. One caveat, the more you manipulate an image, the more data you lose. Getting as close to the final image as you can when you initially take it is by far the best approach.

Without further ado, here's the original image:

aaa.sized.jpg


(Follow this link for the full-sized original image)
 
First thing's first, fire up the Curves tool. (Ctrl-M is the hotkey, or Image->Adjustments->Curves).
We only want to change the amount of blue, not the overall brightness of the image, so select the Blue channel from the menu at the top of the tool, as shown in the screenshot below.

aah.sized.jpg


(Slightly larger screenshot here)
 
Last edited:
One simple approach would be just to reduce the blue channel in the midtones, where they're most likely to interfere with the other colors. This is similar to how the Levels tool, which I'll explain in the PS Elements version of this, will be fixing the blue cast.

The curves tool just creates a map from input values from 0-255 (bottom), and outpu values from 0-255 (left). If I wanted to reduce the amount of blue in the areas with the most blue, I would click on the top-right of the curve and move it down. That's not what we want though, since the areas with that much blue are probably really blue, so they should stay that way.
However, we could click in the middle and pull that down and a little to the right to shape the curve to be lower in the middle. That will pull the midtones down, while leaving the highlight and shadows anchored, as seen below.

This works, but it unfortunatly removes a bit more blue from the vivid blue sections between the green than we want. It also causes the whole image to take on a bit of a green cast due to manipulating one channel across the entire range.

aag.sized.jpg



(Slightly larger screenshot here)
 
Instead of this, lets find out where the actual areas we want to change are. We know we want some reduction over the entire image, but more in some parts than others.

The curves tool provides that. Just click on an area in the image and it will show you where on the curve that section is. Starting with the blue highlights, we can see that those are in the upper quadrant of the curve as shown below.
These sections should probably be pulled down less than the green sections where there's less obvious blue in them.

aab.sized.jpg



(Slightly larger screenshot here)
 
Here's a similar screenshot, this time selecting one of the adjacent green areas. You can see that its about halfway down the curve from the blue one. That gives us something to work with.

(My pointer is somewhat hard to see in these previoous couple of screenshots, but its there if you look close and what to see exactly where I was getting those values from.)

aac.sized.jpg



(Slightly larger screenshot here)
 
Here's the curve I ended up with. I pulled down the middle, then set points along the curve so that it sloped gradually up towards the midtone point I wanted. The fixed the green pretty well.
The upper half of the curve slopes up much more sharply, so that the blue areas have almost as much blue as the original image, as you can see from the upper quadrant, which is almost the same as the original line.

(I think I might have overblown it a bit, but I'm not 100% sure what this mushroom should look like. If you try this, play around with it a bit to see what you come up with.)

aad.sized.jpg



(Slightly larger screenshot here)
 
Last edited:
A little bit of sharpening is added to bring out the ridges on the mushroom (I'll go into sharpening in another thread), and we have a corrected image.

Please let me know if you have any comments of questions, I'll be more than happy to answer them. Hopefully I'll get the PS Elements version up in a day or so, I'm still trying to teach myself how to use Elements.

A thumbnail-based gallery of the images and screenshots with summaries of what I said here can be found at: http://pics.llarian.net/album09

aae.sized.jpg



(Full-sized corrected image here)


-Dylan
 
Llarian said:
One simple approach would be just to reduce the blue channel in the midtones, where they're most likely to interfere with the other colors. This is similar to how the Levels tool, which I'll explain in the PS Elements version of this, will be fixing the blue cast.


Adjusting the white balance on our cameras before taking pics makes complete sense to me and like you said, doesn't cause us to lose a lot of data.

What I don't understand is why the midtones interfere with other colors. Using logic (yeah, I know Curt + logic = nothing), it seems to me that the extreme ends of the color band would be the problems.

Don't feel the need to answer this question right away. I'm just talkin' with my fingers.
 
Curtswearing said:
What I don't understand is why the midtones interfere with other colors. Using logic (yeah, I know Curt + logic = nothing), it seems to me that the extreme ends of the color band would be the problems.

Good question, and I'll see if I can get some hard data to answer it. My basic answer is that when you isolate a channel, the lower levels are either part in the image that're shadows (don't care, for our purposes here), or clearly made up of the other two colors. (In our case, either red, green, or some combination of the two) Likewise, a highlight on a single color channel is almost certainly that color, even if you have a distinct color cast over the whole image. (Or its white, but I don't think you'll see much of that in reef photography. If you DO have a true white section in the image (as opposed to a blown highlight), you can use that to reset the white balance after the fact, but my experience with digital has shown that almost never happens and you need to be able to work with an image where there is no whitepoint available.

Midtones, on the other hand, are some combination of the 3 channels. If I have a distinct blue cast, I don't care about the blue highlights so much because those areas are probably blue anyways and will suffer if I push them towards another color*. Shadows won't change much period unless I'm increasing the contrast and brightness of that area, which should be done before the steps I'm talking about anyways.

The midtones, on the other hand, are some mixture of the 3 channels together. Some examples of what I did to the image in numbers:

Green part of mushroom (midtone blue): pre-correction (85,120,150), post-correction: (85, 120, 90) The blue was very clearly casting the green that should have been dominating that section. Pulling the blue down to roughly the same as the red value gave it a similar luminance, but the correct color.

Blue part of mushroom (highlight blue): No change to speak of here. It stayed more or less as it should, slowly blending to greenish towards the edge and the midtones, which is how it appears to me in the original less the blue cast.

Cove under the liverock (shadow blue): Pre-correction (18,41,41) post-correct (18,41,63) Obviously a bit of a cast to it in the original, which I pulled down a little towards the bottom of the curve, but it didn't look near as off as the mushroom did.

The purple corraline on the live rock also fell into the midtone category, although it wasn't as noticably different because there was more blue in it the begin with, so it feel on the part of the curve where it was sloping up faster towards the highlights.

Did that make any sense at all? heh. I don't feel like I'm explaining this one very well.

-Dylan

* (simplified, if you look at my curve, I clipped the highlights from 255 to 230-240 because it looked better).
 
Originally posted by Llarian Midtones, on the other hand, are some combination of the 3 channels-Dylan

I think I finally understand. I realize my quote is greatly oversimplifying things so I think everyone should read every post. Thanks a bunch!!!
 
WOW! Thanks for doing this Llarian! Great information!

....she took that's in focus
you did an awesome job with the picture...I'm not the best photographer, but you made this photo look great! Even though most other shots, especially fish, are not in focus....grrrrrr :D

I need to read through the "midtones" response again, as it is early in the morning, and my brain is not functioning quite right yet.

I look forward to more tutorials!!
 
Llarian, do you think we should try and customize our white balance in order to correct the blue issues? Using something like white paper?
 
NaH2O said:
Llarian, do you think we should try and customize our white balance in order to correct the blue issues? Using something like white paper?

Whenever possible, yes, absolutely.

The hard part with a tank is getting it in the equivalent light that's being seen through the glass. Unless you have a piece of waterproof white or grey paper, you'll not be able to account for the diffraction of the glass and the diffusion of light through the water. It should get it much closer however, and then you can fine-tune from there.

-Dylan
 
Llarian, can you make this a sticky in your section bud. Please, do so with all these how to's that you write.

-Erik
 
So I've been fighting with PSE (Or more specifically, the Levels too) to try to duplicate the effect I had above, without ever being particularly satisfied with the end result. The closest I can get is the second image I posted, more or less, which looks a little too green to me, but I suppose its a bit better than the original image.

As soon as I have time, I'll whip up a couple quick screenshots to show how to achieve at least that.

-Dylan
 
Llarian said:
Unless you have a piece of waterproof white or grey paper, you'll not be able to account for the diffraction of the glass and the diffusion of light through the water.
PVC pipe will work for this,,it least it has for me!
 
Witfull said:
PVC pipe will work for this,,it least it has for me!

Oh, I didn't think about that. That should be about perfect, and its something white and waterproof.

Wanna post that in the "Photography Tips" thread?

-Dylan
 

Latest posts

Back
Top