details about camera white balance

Hi thanks at first for your work. I'd like to know more about details camera white balance. I noticed that there is a variable called cam_mul, which is a list containing 4 float numbers. How does this variable is used? Multiply each number in cam_mul with the corresponding channel? But in some raw files, I noticed the fourth number of cam_mul is zero. Is there something wrong?

Forums: 

some camera records four

some camera records four multipliers, while some (RGB/3 color) may use only three. In the second case, the cam_mul[1] (Green) should be copied to cam_mul[3] ('second green')

After that, cam_mul[] is usually normalized (i.e. divided to smallest value, so [1500,1000,1200,1000] will become [1.5,1,1.2,1])

And, yes, then color channels are multiplied to cam_mul[color] values.

-- Alex Tutubalin @LibRaw LLC