Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.



Applying a material with ReferenceImage shader to an object, will force the engine to render that object without any shading and post-processing effects.

In other words, the object is colored by the given diffuse texture in such a way that no texture colors are altered in any way.

This shader can be used to color an object with an image and use it as a reference when comparing between some concept art and the engine's output. See: Reference Pictures.

For example, consider the following image:

Image Modified
Figure 1: Reference image of a cove.

If the image is placed inside the editor (a box was used in this example) and rendered with the Illum shader, incorrect output will occur due to post-processing effects such as tone mapping and fog.

Notice the bluish tint and the distorted brightness levels:

Image Modified
Figure 2: The effect of the Illum shader on the reference image.

On the other hand, ReferenceImage shader avoids those problems and reproduces accurate results:

Image Modified
Figure 3: In this snapshot, the reference image is shaded correctly by the ReferenceImage shader.


Diffuse textures in CryENGINE are assumed to be stored in sRGB color space. This means that before the texels are stored in that texture, their values are adjusted by a gamma transfer function (roughly ?=1/2.2) effectively making the image look darker.

Due to this process, the engine converts the diffuse textures back to linear space (making them brighter again) during the loading in order to match the original colors.

On the other hand, data textures like normal bump maps are stored in a linear space from the start so if such texture is used with the ReferenceImage shader, the result will look brighter than the original image.