Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
isp:imagesignalprocessing [2018/05/29 22:41] – [Overall idea] Igor Yefmov | isp:imagesignalprocessing [2018/06/04 12:50] (current) – removed Igor Yefmov | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ======= Image processing ======= | ||
- | |||
- | ====== White Balance ====== | ||
- | ===== What is white color temperature ===== | ||
- | A " | ||
- | |||
- | {{: | ||
- | |||
- | When a scene is illuminated by " | ||
- | |||
- | For our purposes, we are using individual color channel **gains** to compensate for a given temperature. Lower temperature "white light" needs a lot of blue added to it and very little red and as the temperature climbs up, the amount of added red grows while the added blue goes down. | ||
- | ===== Color correction for white temperature ===== | ||
- | For the calibration purposes we have acquired a Philips "Hue White and Color Ambiance A19 LED Starter Kit" that allowed us to test various illumination scenarios for a range of color temperatures. For a given white color temperature setting we have dialed the red and blue gains to make the scene " | ||
- | |||
- | Corrections to the red channel were way more noticeable than those to the blue one so we approximated the blue gains' graph with a single line, described by the formula '' | ||
- | |||
- | Red channel gains are approximated by two line segments, bordering the '' | ||
- | |||
- | below '' | ||
- | above '' | ||
- | |||
- | {{: | ||
- | ==== Experimental data and verification ==== | ||
- | Here is the table with the results of that testing and corresponding calculated values based on the above formulae: | ||
- | | ::: ^ Manually set ^^ Calculated | ||
- | ^ Color, K ^ Red ^ Blue ^ Red ^ Blue ^ | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | | '' | ||
- | |||
- | ===== Practical example ===== | ||
- | What does all that mean in practice? Suppose you have set up your scene with " | ||
- | |||
- | ===== Automatic white balancing ===== | ||
- | Quite often end users don't have the patience or the expertise (or both) to properly set up the white balance of the captured scene and prefer to rely on camera "just knowing what to do". | ||
- | |||
- | Many algorithms are available today to deal with this, some very sophisticated (and computationally expensive) and others, way less computationally expensive but so simple that they are easily thrown off by thins like a huge green screen background or a bright super-yellow T-shirt. | ||
- | |||
- | Below is one of those " | ||
- | ==== Overall idea ==== | ||
- | The general idea is based around an assumption that if one takes a look around and measures the color of every pixel, then the grand total sum of all those values should be close enough to a pure grey color. This idea has a name and it "the grey world" | ||
- | |||
- | ==== Step-by-step algorithm ==== | ||