---
title: "Color Management with V-Ray"
canonical: "https://documentation.chaos.com/space/VMAYA/111740595/Color%20Management%20with%20V-Ray"
format: markdown
---
This tutorial explains how to use Maya's Color Management System with V-Ray.


## **Overview**

---

The V-Ray VFB applies display corrections in the sRGB and gamma 2.2 color spaces.

From the Maya Color Management System, V-Ray supports the **Raw, sRGB** and **ACEScg** spaces, and the color spaces that begin with the prefix **gamma**.

Want to follow along but don’t have a license?


> Macro (ui-button)





## **Tutorial Steps**

---

### Set up the Scene

1. Set up a scene with an object that has a material with a JPG texture connected to it.
2. Render the scene.
3. In the V-Ray VFB, enable and disable the **Display colors in sRGB space** button and note the difference in the appearance of the rendering. This shows how the texture looks with and without gamma correction. When **Display colors in sRGB space** is off, the image appears with no gamma correction, and looks as expected. When this option is on, the image is gamma-corrected in the display, and the image looks washed out.


  
When **Display colors in sRGB space** is on, the texture is being double gamma-corrected. The texture is already gamma-corrected when it is applied, and then it is again gamma-corrected as part of the rendering process.  
  
Essentially, the texture does not conform to a linear workflow as it is already gamma-corrected when it comes into the shading node. In a linear workflow, all textures brought into the scene are not gamma corrected (that is, they have a gamma of 1.0), and the only gamma correction is on the final rendering. In order to conform to Linear Workflow, you would need to undo (reverse) the gamma correction on the texture as it comes into the scene.


### Use Maya Color Management

---

##   
**Enable Color Management Example**

---

The example below shows the difference between **Enable Color Management** being turned on and off. This uses a more complex scene where the use of Gamma correct nodes would be time consuming and turning on the **Linear workflow** option in the **VRay** tab of the **Render Settings** would give an incorrect result.


## **Color Management Rules Example**

---

V-Ray for Maya fully supports Maya's native <span style="color: #000000">Input Color Space Rules. These are set in Maya's Color Management preferences and a rule will determine the input color space that is assigned to begin with based on the file extension, the file naming conventions that are used, or both of these together.</span>


![image](media://5721d91f-4c87-4ff6-8744-c22301d4cfae)

<span style="color: #000000">In such a way a rule can be set up so that any texture that contains the text "Diffuse" in its name would then be set to sRGB color space.</span>


![image](media://9eeda9dc-0a36-46ac-ab1e-36d538dc4468)

<span style="color: #000000"> </span>

<span style="color: #000000">**Another rule could be set so that if the file name contains the text "Normal" then its Input Color Space would be set to Raw.**</span>


<span style="color: #000000">By using rules in the above example, we make sure that all diffuse JPG files will be corrected for the sRGB color space, while our normal textures coming in from JPG files will not be corrected so that normal bump mapping is correctly rendered.</span>


<span style="color: #000000"> </span>

## **Notes**

---

- Color Management is available in Maya 2016 and later versions
- Currently, V-Ray for Maya supports the following Input Color Space types:
  - Raw
  - sRGB
  - sRGB Encoded Rec.709 (sRGB)
  - sRGB Encoded AP1
  - sRGB Encoded P3-D65
  - gamma 1.8 Rec 709
  - gamma 2.2 Rec 709
  - gamma 2.4 Rec 709 (video)
  - gamma 2.4 Encoded Rec.709g
  - gamma 2.2 Encoded Rec.709
  - gamma 1.8 Encoded Rec.709
  - gamma 2.2 Encoded AP1
  - gamma 2.2 Encoded AdobeRGB
  - Linear Rec.709 (sRGB)
  - Linear P3-D65
  - Linear AdobeRGB
- V-Ray displays a warning when a texture with color corrections is being used as a normal map. This applies to any V-Ray material that can use normal maps in a bump map slot.
- The Gamma Correct nodes within Maya can be used to inverse correct the textures to conform to a linear workflow. This can be done by inserting a Gamma Correct node with a value of 0.454 in between the File Node and the shader. To properly work within a linear workflow, you would have to add a Gamma Correction node to every texture you use in your scene. Alternatively, *Texture input gamma* attributes can be added to the File node as Extra V-Ray attributes, but again this would yeild adding those attributes to all File nodes in your scene. This can quickly become unwieldy, and is unnecessary when there are easier options available. which is why it is recommended to use the Color Management system available in Maya 2016 and later versions.

> ⚠️ ![image](media://01a2d968-a773-4c6a-856e-7607d88bb98a)
> ⚠️ 
> ⚠️ 
> ⚠️ The older legacy approach to a linear workflow for when a scene had a lot of texture nodes was to turn on **Linear workflow** in the **VRay tab** of the Render Settings. However, this is no longer recommended as that particular workflow will only gamma correct textures in the Diffuse and will fail to gamma correct textures connected to other channels of materials within a scene. Also if a shading network is long or complex, textures can get skipped. For these reasons this method is no longer recommended.