applycal
Author: Graeme W. Gill

## profile/applycal

### Summary

Apply, re-apply or remove calibration curves to an ICC profile.

### Usage Summary

usage: applycal [-options] [calfile.cal] inprof.icm [outprof.icm]
-v Verbose mode
-a Apply or re-apply calibration (default)
-u Remove calibration
-c Check calibration
calfile.cal Calibration file to apply
inprof.icm ICC profile to read
outprof.icm modified ICC profile to write

### Usage Details

The -v flag makes applycal more verbose.
-a By default the calfile.cal is applied or re-applied to the inprof.icm, and then written to outprof.icm.
-u This flag causes any calibration applied to the inprof.icm to be remove, the profile being restored to its pre-calibrated state, and then written to outprof.icm.
-c This flag checks the inprof.icm and if verbose is on, reports whether it has had calibration applied. It will return status 0 if it has not been applied, 1 if it has, and 2 on error.
calfile.cal must be supplied if the calibration is being applied or re-applied.
inprof.icm should be the path to the ICC profile that will have calibration applied, re-applied or removed. The appropriate extension should be used for the platform, i.e. icm for MSWindows, and icc for OS X or Unix/Linux.
outprof.icm should be the path to the file that will be created to hold the modified ICC profile. The appropriate extension should be used for the platform, i.e. icm for MSWindows, and icc for OS X or Unix/Linux.

### Discussion

Applycal provides a means of using per channel calibration on devices and systems that don't explicitly support such calibration. Once a calibration has been created for a device (see printcal), it needs to be then used for all subsequent profiling and printing. If the printing device, display or system doesn't explicitly support the use of calibration, then the calibration can be applied during the printing of profile test charts using printtarg -K, or the reading of a display target using dispread -K, and then for processing imagery using cctiff or by modifying the device ICC profiles using applycal.
Applycal modifies the appropriate input or output per-channel curves of the profile to incorporate the per-channel calibration. To allow the calibration to be re-applied or removed, it first makes a copy of the uncalibrated curves and stores them in private tags in the profile.
NOTE that things like the white point, black point tag, gamut tag etc. are not adjusted to account for the calibration, nor does applycal read, add or change any 'vcgt' tag (If a 'vcgt' tag is present and a calibration applied as well, then both will be in effect when such a profile is installed using typical display installation tools.)
NOTE that any calibration embedded in the ICC profile 'targ' tag is ignored, since it is intended for computation of final calibrated device value ink limits, and may not represent the exact current calibration curves.