A LUT (Lookup Table) is essentially the modifier between two images, the original image, and the displayed image, based on a mathematical formula. Any color transformations made to the LUT will be applied to the resulting filter.

LUT based filters affect the whole image they are applied to and have no knowledge of surrounding pixels. This means filters such as blur or sharpen cannot be implemented via LUT based filters.


As a rule, any global color transformations will work with this approach, whereas any tool or transformation which requires the knowledge of pixel location or surrounding pixels will not. Here is a table of some common tools or transformations:

Making an LUT

Before you can make your postprocessing effect, locate the default LUT.

This table holds no color transformations, ie. when using this default LUT every color value is transformed into itself.

1. Load the default LUT into the image editing software of your choice

These instructions will use screenshots from Photoshop.

All color transformations you make to the identityLUT.png image will be applied to the resulting filter. For your reference, you can also load a photograph to another layer.

2. Choose a transformation you wish to apply to a filter

Options listed in Photoshop's Adjustments menu should all work well with this method.

As an example, we can adjust the hue, saturation, and lightness on the reference image and the default LUT.

Once you are satisfied with the results, make sure to disable or delete the reference image layer.

3. Save the result as a new LUT

LUTs should be saved as png files with no compression (maximum quality).

In this example the saved file is named newLUT.png, whenever newLUT.png is used in this example you should use your LUT texture.

LUT Postprocessing effect

This example will show how to use a prepared LUT texture in DeepAR Studio to create a postprocessing effect. Different effects can be achieved by simply using different LUT textures.

  • Open the DeepAR Studio

  • Now go to create new effect File → Create new effect

  • Next, add quad via Node → Add quad

  • Select Root in the Node hierarchy

  • In the Node properties set Position mode to the position in camera space

For postprocessing effects to work properly quad node must be in the Post process layer:

  • Select Root → quad node in the Node hierarchy

  • In the Node Properties section, in Layer drop-down box select Post process layer

We need to load the LUT texture which contains the desired color transformations.

  • Go to the Textures tab Add → Texture

  • Choose newLUT.png in the LUT_filter_example folder or any other LUT file you want

  • When loading LUT textures always select the PNG - 100% texture quality

  • Select Root → quad node in the Node hierarchy

  • In the Material Properties section under the Select shader list, choose the LUT shader

  • Set the Input texture to Postprocessing texture

  • Set the LUT to newLUT.png

  • Hit Reload button

Download this example with all assets

Did this answer your question?