Re: colour channels in the histogram and 'good' white balance
Quote:
Originally Posted by
davidedric
From another angle (I think!). With most graphical representations, the Area Under the Curve (auc) represents some real physical quantity. Can anyone enlighten me as to what the auc of a histogram represents? As a specific example, the difference between a flattish histogram and a higher one, with the same relative peaks heights from left to right?
The histogram is luminance (x-axis) by density (y-axis). So it seems to me that the relative areas under the curve should represent the total proportion of pixels of each color, across all levels of luminance. I'm hedging with "proportion" because I don't believe the y axis is scaled to represent a count. I think most software rescales it to fill the vertical space, but I don't actually know for certain.
Re: colour channels in the histogram and 'good' white balance
Quote:
Originally Posted by
davidedric
...Can anyone enlighten me as to what the auc of a histogram represents? ...
I'm not a Moderator but I did start this thread so please can I ask you politely not to pirate a thread like this? If you have a new question please start a new thread.
Thank you,
Ken
Re: colour channels in the histogram and 'good' white balance
Actually, I think the answer is very relevant to your original post, since it seeks to understand what the histogram is actually displaying. However, as you are the OP I will of course desist.
P.S. please see also pm
Re: colour channels in the histogram and 'good' white balance
Okay; let's look at some histograms. These were created in Photoshop; we have a histogram of pure black with RGB values of (0,0,0), middle gray (128,128,128) and white (256,256,256). Not surprisingly, the histogram has a single bar that goes all the way up the y-axis.
http://backup.cambridgeincolour.com/...9f0325af_b.jpg
The second image is 50% white and the rest of the image is a picture of a timber wolf lying on some snow. I also show a histogram of the image of the wolf only.
http://backup.cambridgeincolour.com/...31e8d4b3_b.jpg
I suspect that this bar on the right side of the histogram going all the way up the y-axis is what Steve is referring to. The full image also shows a bar all the way up the right (and I double checked; there is no highlight clipping in the image). This is where I am coming from when I say there is no way to glean white balance information from the histogram because we cannot disagregate the pure white from the rest of the image.
Re: colour channels in the histogram and 'good' white balance
Manfred,
I assumed Steve was talking about a display of separate histograms of all of the color channels.
If I understand right, all a monochrome histogram tells you is where along the luminance scale the pixels are clustered. In your shots, as a result of the snow, you have a lot within a short range of maximum luminance, hence the stacking near the right. WB would not affect this. However, the color temp of the light source would change the histograms of the color channels.
I never use the histograms to analyze WB because the position and size of the various histograms depends on the source (the scene). however, I find it very useful to leave my camera set that way because I often find that one channel (most often, the red) is clipping when the exposure in the other channels is low enough that the monochrome histogram shows everything to be fine. I have lost detail in a number of flower shots that way.
Dan
Re: colour channels in the histogram and 'good' white balance
And that's when you use the grey point 128/128/128 (if you can see the right side of the histograms and there is white in the image, then all you have to do is adjust the right side. 256/256/256)............... (notice all three color channels are the same number.................ta da :D)............ Aligning the histograms to a neutral point. It may not be what you like, but it is a base line for adjusting an image.
Re: colour channels in the histogram and 'good' white balance
Quote:
Originally Posted by
DanK
Manfred,
I assumed Steve was talking about a display of separate histograms of all of the color channels.
If I understand right, all a monochrome histogram tells you is where along the luminance scale the pixels are clustered. In your shots, as a result of the snow, you have a lot within a short range of maximum luminance, hence the stacking near the right. WB would not affect this. However, the color temp of the light source would change the histograms of the color channels.
I never use the histograms to analyze WB because the position and size of the various histograms depends on the source (the scene). however, I find it very useful to leave my camera set that way because I often find that one channel (most often, the red) is clipping when the exposure in the other channels is low enough that the monochrome histogram shows everything to be fine. I have lost detail in a number of flower shots that way.
Dan
We are not talking about monochrome, we are talking about color. Black / white / grey are all colors in a color image. The mix of colors R G B for these colors are all the same( pure black is 0,0,0---50% grey is 128,128,128---white is 256,256,256. When you adjust the white balance and map white to 256,256,256 all the other colors follow, thus adjusting the white balance.
Re: colour channels in the histogram and 'good' white balance
Let me try approaching this from a slightly different direction.
I've created three colour patches in Photoshop and on a blank (no content background, which gets converted to a white background when written to jpg). I isolated each patch and showed the histogram for each channel. Each colour has a value of 255; i.e. the red patch is (255,0,0); the green has values of (0,255,0) and the blue is (0,0,255).
http://backup.cambridgeincolour.com/...852826fd_b.jpg
So the histogram for each channel properly shows each swatch as 100% full colour value; BUT they are not in the same location, so we cannot assume that they represent a white value, even though the data is at the right side of the histogram. The bottom line is that the histogram is just the distribution of quantity (y-axis) of the value (0 -255) on the x-axis. It may or may not show the white value.
Re: colour channels in the histogram and 'good' white balance
I just now returned to the thread after being away from it all day and I don't believe the attention that is being given to the values of RGB on a single point of the X axis has anything to do with the OP's question. As I provide that question below as a convenience, I would like to point out that the question refers to an alignment of the color channels, meaning each entire channel, not one luminosity value such as 128 or 255.
Quote:
Originally Posted by
stuck
I'm wondering if one way of knowing that the colour balance is close to correct is to look at the alignment of the colour channels on the histogram. 'Right' being when they all more or less line up/overlap, as opposed 'wrong' when one channel is offset relative to the others.
As such, my answer to the question remains that no, that alignment provides no indication as to whether the color balance is close to correct.
Re: colour channels in the histogram and 'good' white balance
Well, I did manage to get decent WB settings with adjustments based on the histogram.
A few conditions though:
there must be some white in the image
highlights shouldn't be clipped
I use a multicolour histogram in log mode (Y values are on a log scale), and adjust to
have the right flanks for each colour coincide. It works very well on things like landscapes
and other scenes with some pure white as highlight.
@Steve: your demonstration of the use of the gray point on the flower picture is severely flawed:
that particular image was taken with a custom WB set with a WiBal card (see Dan's post), so
the WB in the original was technically correct (except in case of operator error). Adjusting the
grey point would then give a completely false WB, and colours that are way off. (Note that
the green in the centre of the flower is supposed to have a yellow cast, as it is surrounded by
yellow petals)
Re: colour channels in the histogram and 'good' white balance
Ok, i just did a test. I shot an image of a white piece of paper under incadescent light. I set the white balance to 2500K. I shot a base image. Then i created a color cast by shifting the white balance, with my white balance shift feature on my camera. I shifted it to full red, then full blue, then full green. This did as expected, and gave the images a red/blue/green color cast. I then adjusted the right side of the seperate RGB histograms, with color mode set to color. I then adjusted the left side with color mode set to color. Then i adjusted the mid range or grey point.
Adjusting the right side or white point , took the color cast out of the highlights. The black point took the color cast out of the shadows. The grey point took it out of the midrange.
It is apparent that in order to neutralize 'all' color casts, you have to set the black point, grey point , and white point. This will , however, leave the image 100% neutral and prob. cold looking. It will remove all wanted color casts.
What i've been doing with my images, is to set the whitebalance to my liking with the sliders, and then adjusting the mid range or grey point to neutralize any heavy color casts. I'm not using they grey eyedropper, im adjusting it with the curves tool. I use this ,in combination with saturation to warm the image back up.
Most of the time, you're histograms are lined up pretty good, and when you adjust the levels, the colors of the highlights and shadows are very close to being correct. It's the mid range , that i find is off more times than not. Don't know if it is right or wrong, but that's the way i like my images for now.
Here are the results of my test.
Base image as 2500k under incandescent light.
http://backup.cambridgeincolour.com/...f/IMG_4010.jpg
Base image with white point adjusted
http://backup.cambridgeincolour.com/...IMG_4010-1.jpg
Base image with black point adjusted.
http://backup.cambridgeincolour.com/...IMG_4010-2.jpg
jThe white point and black point was only levels adjustment , not color corrections.
Base image color corrected in the mid range
http://backup.cambridgeincolour.com/...IMG_4010-3.jpg
For each of the color casts, the first is straigt out of the camera, the second is white point adjusted, third is black point and white point adjusted and fourth is Black, white, and mid range adjusted.
Red cast..........
http://backup.cambridgeincolour.com/...f/IMG_4011.jpg
http://backup.cambridgeincolour.com/...IMG_4011-1.jpg
http://backup.cambridgeincolour.com/...IMG_4011-2.jpg
http://backup.cambridgeincolour.com/...IMG_4011-3.jpg
Green cast..............
http://backup.cambridgeincolour.com/...f/IMG_4014.jpg
http://i194.photobucket.com/albums/z...IMG_4014-1.jpg
http://backup.cambridgeincolour.com/...IMG_4014-2.jpg
http://backup.cambridgeincolour.com/...IMG_4014-3.jpg
Blue cast...............
http://backup.cambridgeincolour.com/...f/IMG_4013.jpg
http://backup.cambridgeincolour.com/...IMG_4013-1.jpg
http://backup.cambridgeincolour.com/...IMG_4013-2.jpg
http://backup.cambridgeincolour.com/...IMG_4013-3.jpg
The last image of each set , are very similar in color correction. Maybe not quite exact, but very very close.
I think this test shows you can get a neutral WB by using the histograms. Maybe not correct to the scene as it was photographed, but neutral.
Re: colour channels in the histogram and 'good' white balance
try it with something that is not white. If you "balance" colors that are not in fact balanced in the image, you won't get an accurate representation. That's why your edits of my peony image were so unnatural and inaccurate. That's why people use a neutral source. (Your white paper was probably reasonably close.)
The bottom line is simply that unless you are shooting a spectrally neutral source, playing with histograms will not necessarily get you closer to correct WB and can easily (as in the peony example) get you radically incorrect WB. In that case, you were starting with an image that HAD correct WB and made it incorrect by "balancing" the histograms. The way to get correct WB is simple: take a neutral source and set the three colors to be equal (as the LR eyedropper does). Luminance is largely irrelevant.
Re: colour channels in the histogram and 'good' white balance
This technique reminds me of the old Photoshop "trick" to do a quick and dirty colour cast removal. It works reasonably well in "average" images. but throw an image with a colour bias at it, it will fail.
Make a duplicate layer of the original image; apply the average blur and then invert these colours. Set the blending mode to Multiply, and voila! Quick and dirty colour cast removal. Try it with an image like your flower Dan, and you get the same false colour result.