How do white balance temperature and tint adjustments change image values mathematically?

Asked 1/21/2021

8 views

2 answers

0

I’m trying to understand what white balance sliders actually do under the hood, especially in Lightroom/Camera Raw. When I adjust temperature and tint, is the software simply changing RGB channels, or is it using a more complex transform?

I’m also curious why changing temperature/tint can alter the look of a black-and-white conversion, while other color tools may add a visible cast or have little effect. Does white balance change luminance values directly, or do chroma changes affect the grayscale mix indirectly?

I’m asking from a software-development perspective: what is the mathematical model typically used for temperature/tint and white balance processing?

Originally by Photography Stack Exchange contributor. Source · Licensed CC BY-SA 4.0

Photography Stack Exchange contributor

5y ago

2 Answers

1

This is a more tricky question that you might think.

First, the RGB value that you see with your eyes on the screen are the result of an operation on the processed output from Lightroom, that is defined by the calibration of you screen. So beware what RGB values you measure.

Second, when you are adjusting color temperature, what you are really doing is reverse-engineering the way your brain interprets the effect of outside light on the object you took a picture of. This is quite a complex process, given that outside lights are not simple RGB rays, but a mixture of. And on top of that not every brain does it the same. And they do not do it linearily. Most experienced and well-staffed software companies are still struggling in 2021 to get it right.

This has been first studied extensively with the determination of the CIE xy model in 1931, which is the godfather of every color processing today and was aimed at defining the "average" understanding of color by humans.

Long story short, you'll need a few hours, or rather days to grasp the math underneath it and if you haven't been taught matrixes, it may be weeks or months...

I suggest if you are interested you look for colorimetry theory to get familiar with the subject.

Originally by user71772. Source · Licensed CC BY-SA 4.0

user71772

5y ago

0

AI Answer

Generated from our catalog & community — verify before relying on it.

White balance is not usually a simple “add blue” or “raise one RGB channel” operation. In raw processors such as Lightroom/Camera Raw, it is typically handled as a color-space transform from the camera’s native sensor space to a standard color space using a white point defined by temperature/tint.

Per Adobe’s DNG model, the software uses calibration matrices (for different illuminants) and interpolates between them to map camera color to CIE XYZ, typically referenced to D50. Temperature and tint correspond to chromaticity coordinates, not directly to one RGB channel.

So the math is closer to matrix-based color adaptation than per-pixel channel nudging.

Why can it affect black-and-white? Because a B&W rendering is usually derived from the image’s color data before or during conversion. If white balance changes the underlying color relationships, the grayscale mix can change too. That doesn’t necessarily mean LAB a/b channels directly become luminance; it means the conversion to grayscale depends on the image’s color values after white balance.

In short: temperature/tint usually changes the color transform and white point, and grayscale output can change because it is computed from those adjusted colors.

UniqueBot

AI

5y ago

Your Answer