#This post is a wiki post.
This means that anyone with trust level 2 or higher will be able to edit this post. If you have an idea or can take a minute to contribute to the contents, please do! (See the first response to this post.)
Customize CLUT – A bit like 3D curves.
Curves are one of the most versatile and often used tools for manipulating photos. The basic principle is that you can take an input value and map it to a new output value. Typically the user will set a few values to change and the software will interpolate a smooth, predicable change between the user set changes and all of the other values. Curves, however, are limited to one dimension. That is, you are only changing the intensity of one channel (eg red or green or blue).
Digital photographs are represented in three dimensions, each dimension is a colour channel and it forms a 3D cube of all of the possible colours in the image.
A Colour Look Up Table (CLUT) is list of all of the colours in a colour cube and new values that each colour should be changed to. Explain more here.
A Customize CLUT filter is available in G’MIC. It allows a full Colour Look Up Table to be made by specifying input and output, just like curves, but in three dimensions. It’s not complicated. It’s as easy as specifying an input colour you want to change and the colour you want it changed to. All of the other colour changes are interpolated from known points to produce smooth colour changes across the whole colour cube, just like the rest of the values are when using curves.
Lets look at an example. To keep it simple we will use a black and white image. If you set the input colour white to replaced in the output with black, and black to replaced in the output with white, all of the values in between are interpolated and you get a negative of what you started with.
We could replace white with cream and black with navy and get a split tone effect. Make sure your original image in GIMP is in RGB mode, not Greyscale, otherwise you will not see the effect.
To make things easier the filter allows you to ‘lock uniform sampling’ which has a number of options to make certain colours stay the same in the output unless you override them. If you set this to '8 keypoints (RGB corners) then the output image will match the input image.
Now here’s an example of changing a colour image. First we lock the 8 corner keypoints, then we replace red with blue and magenta with pale blue and the colour of the car is now blue.
The problem is that, with only a few keypoints specified other colours are changed as well. If we add more keypoints to lock colours so they aren’t effected, and a few more to make sure the colours we want changed are doing what we want, then we can get a much better result.
Here are the 14 points I used. Expand image to see all of them.
This is not the only way to change the colour of a car, and might not be the best way, but it is intended to illustrate the function and potential of the Customize CLUT filter.