Photography‎ > ‎

Whitebalance

whitebalance is a Gimp script for changing the white balance of images. This script-fu script can be used to convert the foreground color to either a neutral gray, or to the color of the background. The conversions are performed in the sRGB color space. In Gimp 2.4 and later, more colorspaces are supported, but the plugin has not yet been adapted to work with general colorspaces.

Once installed, the script is available from the menu item Filters/Colors/White Balance.

Download

  • Download whitebalance.scm for Gimp 2.2, 2.4, and 2.6 from the attachments section at the bottom of this page.
  • To install, put the script in the appropriate directory, then click on the menu Filters / Script-Fu / Refresh Filters.  On the Mac, the appropriate directory is Library/Application Support/Gimp/scripts/

Usage

The script can be used in two ways:
  1. Make foreground gray. In this mode, the colors are scaled so that the foreground color assumes a gray tone. Note that an actual gray tone may not be achieved, if clipping occurs in some color channel.
  2. Convert foreground to background. In this mode, the colors are scaled so that the foreground color is converted to background color. Again, a perfect match may not be achieved, if clipping occurs in some color channel.
The Conversion amount slider can be used to determine the amount of converstion, from 0% (no change) to 100% (full conversion). This can be used to leave some of the original color cast in the image, which often yields more natural results.

The Intensity slider is used to modify the intensity of the image; this can be useful to avoid clipping of color channels. The slider specifies the intensity of the new image as a percentage of the intensity of the old one.

The Saturation slider can be used to modify the saturation of the image. Sometimes, when performing a large change in white balance, the effect is more natural if the image is desaturated a little bit.

The conversion is done in the official sRGB color space, taking into account of the definition of gamma for sRGB.

If your intent is to correct the red or blue cast of photos taken in different lighting conditions, you may want to consider using the colortemp script-fu.

ċ
whitebalance.scm
(5k)
Luca de Alfaro,
Feb 26, 2009, 12:31 AM
Comments