Copyright © Fred Weinhaus My scripts are available free of charge for non-commercial (non-profit) use, ONLY. For use of my scripts in commercial (for-profit) environments or non-free applications, please contact me (Fred Weinhaus) for licensing arrangements. My email address is fmw at alink dot net. If you: 1) redistribute, 2) incorporate any of these scripts into other free applications or 3) reprogram them in another scripting language, then you must contact me for permission, especially if the result might be used in a commercial or for-profit environment. Usage, whether stated or not in the script, is restricted to the above licensing arrangements. It is also subject, in a subordinate manner, to the ImageMagick license, which can be found at: http://www.imagemagick.org/script/license.php Please read the Pointers For Use on my home page to properly install and customize my scripts. |
Transforms an image's overall color balance according to a desired color temperature change. |
last modified: December 15, 2018
USAGE: colortemp [-t temperatures] [infile] outfile
-t ... temperture(s) .... t1[,t2]; 1000 to 40000 deg K PURPOSE: To transform and image's overall color balance according to a desired color temperature change. DESCRIPTION: COLORTEMP transforms an image's overall color balance according to a desired color temperature change. If no infile and no temperature is provided, the script will generate a color vs temperature chart. If no infile is provided, but a desired temperature is specified, then the script will generate a color swatch for the specified temperature. ARGUMENTS: -t temperature(s) ... TEMPERATURE(S) specifies the desired (t1) temperature and the current (t2) temperature. Values range from 1000 to 40,000 deg K. The default for t2 is pure white which is near 6500 deg K. -f fov ... FOV is the observer's field of view. Allowed values are fov=2 or 10 deg. The default is 2. Differences in color temperature are slight between the two. infile outfile ... If no infile and no temperature are provided, then outfile will be a color vs temperature chart. If no infile but t1 is provided, then outfile will be a color swatch for the provided temperture. If infile and t1[,t2] provided, then infile will be color transformed to generate the outfile according to temperture(s) provided. Requires NetPBM (http://netpbm.sourceforge.net/) CAVEAT: No guarantee that this script will work on all platforms, nor that trapping of inconsistent parameters is complete and foolproof. Use At Your Own Risk.
Some Common Illumination Color Temperatures
|
Color Temperature Transformation Of An Image |
|||||
Original Image |
|||||
![]() |
|||||
Arguments: |
Arguments: |
Arguments: |
Arguments: |
Arguments: |
Arguments: |
![]() |
![]() |
![]() |
![]() |
![]() |
![]() |
Color vs Temperature Chart |
|||||
Arguments: |
|||||
![]() |
|||||
Arguments: |
|||||
![]() |
Color Swatches |
|||
Arguments: |
Arguments: |
Arguments: |
Arguments: |
![]() |
![]() |
![]() |
![]() |
Arguments: |
Arguments: |
Arguments: |
Arguments: |
![]() |
![]() |
![]() |
![]() |
What the script does is as follows:
This is equivalent to the following IM commands:
|