
http://www.littlecms.com
Copyright © 2013 Marti Maria Saguer, all rights reserved.
Engine API 2.5
By Marti Maria

2
Contents
Requeriments ...................................................................................................................................... 5
Dependencies .................................................................................................................................. 5
Installation ........................................................................................................................................... 5
Linux/unices .................................................................................................................................... 5
Windows
®
MS Visual Studio ............................................................................................................ 6
Windows
®
Borland C++ 5.5 .............................................................................................................. 6
Apple
®
Mac ...................................................................................................................................... 6
Other ............................................................................................................................................... 6
Configuration toggles ...................................................................................................................... 7
DLL COMPILATION and use (Windows
®
only).................................................................................. 8
Asserting .......................................................................................................................................... 8
Included files (dependencies) ......................................................................................................... 9
Generic types .................................................................................................................................... 10
Common constants ........................................................................................................................... 11
Plug-Ins .............................................................................................................................................. 12
Context ID .......................................................................................................................................... 13
Dynamically changing the input/output formats .............................................................................. 14
Error logging ...................................................................................................................................... 16
IO handlers ........................................................................................................................................ 18
Profile access funtions....................................................................................................................... 20
Predefined virtual profiles ................................................................................................................. 25
Obtaining localized info from profiles ............................................................................................... 35
Profile feature detection ................................................................................................................... 37
Accessing profiler header .................................................................................................................. 38
Device attributes ........................................................................................................................... 41
Profile classes ................................................................................................................................ 42
Profile versioning........................................................................................................................... 43
Info on profile implementation ......................................................................................................... 45
Color spaces ...................................................................................................................................... 46

3
Containers in floating point format ............................................................................................... 49
Colorspace conversions ................................................................................................................. 49
Encoding /Decoding on PCS .......................................................................................................... 52
Accessing tags ................................................................................................................................... 54
Tag types ....................................................................................................................................... 54
Tags ............................................................................................................................................... 55
Accessing tags as raw data ............................................................................................................ 61
Profile structures ............................................................................................................................... 63
Platforms ....................................................................................................................................... 64
Reference gamut ........................................................................................................................... 64
Image State ................................................................................................................................... 64
Pipeline Stages (Multi processing elements) ................................................................................ 64
Formatters ......................................................................................................................................... 67
Macros to build formatters ....................................................................................................... 67
Macros to extract information from formatters ....................................................................... 67
Color spaces in Little CMS notation............................................................................................... 68
Translate color space from/to Little CMS notation to ICC ............................................................ 69
Predefined formatters ................................................................................................................... 70
Intents ............................................................................................................................................... 74
Flags ................................................................................................................................................... 77
Color transforms ............................................................................................................................... 78
Proofing transforms ...................................................................................................................... 81
Multiprofile transforms ................................................................................................................. 84
PostScript generation ........................................................................................................................ 86
Δ E metrics ........................................................................................................................................ 88
Temperature <-> Chromaticity (Black body) ..................................................................................... 91
CIE CAM02 ......................................................................................................................................... 92
Gamut boundary description ............................................................................................................ 94
Gamut mapping ................................................................................................................................. 96
MD5 message digest ......................................................................................................................... 97
CGATS.17-200x handling ................................................................................................................... 99
Tables .......................................................................................................................................... 100

4
Persistence .................................................................................................................................. 101
Type and comments .................................................................................................................... 103
Properties .................................................................................................................................... 104
Datasets ....................................................................................................................................... 108
Screening structures........................................................................................................................ 114
Named color lists ............................................................................................................................. 115
Profile sequences. ........................................................................................................................... 118
Multilocalized unicode management .............................................................................................. 120
Dictionary ........................................................................................................................................ 125
Tone curves ..................................................................................................................................... 128
Parametric curves ........................................................................................................................ 129
Segmented curves ....................................................................................................................... 131
Tabulated curves ......................................................................................................................... 132
Curve handling ............................................................................................................................ 133
Information on tone curve functions .......................................................................................... 136
Pipelines .......................................................................................................................................... 139
Stage functions ............................................................................................................................ 145
Sampling CLUT ............................................................................................................................. 150
Slicing space functions .................................................................................................................... 151
Conclusion ....................................................................................................................................... 153
----------------------------

5
Requeriments
Requeriments
Little CMS 2 requires a C99 compliant compiler. GCC 3.2 and above, Intel compiler and Borland 5.5
does support C99 standard. In addition, Microsoft® Visual C++ 2003, 2005, 2008 and 2010 are
supported as well.
Dependencies
If you plan to compile the tifficc and jpgicc utilities, you need to have following libraries installed.
Please refer to documentation of each library for installation instructions.
tifficc
Lib TIFF
http://www.remotesensing.org/libtiff/
jpgicc
Independent JPEG Group
http://www.ijg.org/
Installation
Linux/unices
Unpack & untar the tarball, cd to the newly created directory and type:
./configure
make
make check
This latter will run the testbed program as well. If you want to install the package, type:
sudo make install
This does copy API include files into /usr/local/include and libraries into /usr/local/lib. You can
change the installation directory by using the –prefix option
There are additional targets on the Makefile:
install: Does install package
check: Builds and executes testbed program
clean: Deletes object & binary files
distclean: Deletes any file not present in the distribution package
dist: Creates the distribution files