• Linear Workflow

    Understanding the colour management pipeline in 3Ds Max and Vray

How to set up Linear workflow in 3Ds Max and Vray

3Ds max works in linear colour space, but our monitor displays in sRGB colour space (perceptual). We need to make sure textures and colours are converted to linear space for rendering, but viewed in sRGB colour space. We also need to be able to select colours in sRGB space and make sure they are being adjusted too.

Why is this important?

3Ds Max works in a linear colour space, but our monitor displays in sRGB colour space (perceptual). Textures such as jpegs, and colours picked in sRGB colour space must be converted to linear colour space for rendering. Floating point formats must not be gamma corrected as they are already a linear file.

While textures are corrected, flat colours are not. We have to de gamma colours, otherwise they receive double gamma and will appear much too bright and washed out.
We also need to input bump, normal and displacement maps with no gamma correction, or a gamma of 1.0.

LDR formats (.jpg, .tga) must be saved in sRGB colour space. HDR formats (.Exr) must be saved in Linear colour space. Vray can either apply a gamma curve to the render, and not apply while saving, or keep the render linear space, preview the image in sRGB space in the frame buffer, and apply a gamma curve to LDR files during the save.

Different methods

There are two main methods we will look at.
Before Vray, there wasn’t an sRGB preview button on the frame buffer.
To view the render in sRGB through the standard 3Ds max frame buffer, you had to burn in the gamma, then save without.
The Vray frame buffer has a preview button to let you see your image with sRGB applied, whilst keeping the image in linear colour space.
It is useful to know both approaches so you know how to handle scenes created by different artists.

Pre Gamma.
Gamma is applied to the pixels during the render.
If you burn the sRGB gamma into your image, you shouldn’t add it again when saving.
You save a .jpg (LDR) as gamma 1.0, and an exr (HDR) as .4545.
A benefit of this method is you can specify the gamma added to the render. 2.2 gamma can look too washed out, sometimes a figure of 1.8 Gives more contrast, and can be previewed in the frame buffer.

Post Gamma.
Gamma is previewed through the Vray frame buffer, and added when saving.
If you preview sRGB through the Vray frame buffer, you don’t actually burn gamma in to your pixels.
3Ds Max will automatically apply a gamma 2.2 to Low Dynamic Range images such as .jpg when saving.
No gamma will be applied to High Dynamic Range images such as .EXR.

  • Vray.

    Pre Gamma Start file.

    input 2.2 – output 1.0 colour mapping and gamma – no sRGB.

    Download .Max file

  • Vray.

    Post Gamma Start file.

    input 2.2 – output 2.2 colour mapping only (no gamma) – sRGB ticked.

    Download .Max file

Pre Gamma Method

Set the System gamma to input 2.2, output 1.0.
The easiest way to do this is to open a file with these settings and adopt them.

Vray Frame Buffer:
Make sure the sRGB preview is disabled.

Gamma/LUT Setup:
(Menu bar/Rendering/Gamma/LUT Setup)
Tick Enable Gamma/LUT Correction
Gamma 2.2
Do not tick affect colour selectors.
Tick Affect material editor.

Vray Render Dialogue:
Colour mapping tab:
Set the gamma value to 2.2
Mode: Set to colour mapping and gamma

Saving LDR files

LDR files such as .jpg and .tga must be saved as 1.0.
The gamma adjustment has taken place during rendering.
With system output gamma set to 1.0, choose automatic and Max will not gamma encode again.

Saving Floating point formats

EXR: select override, type .4545
EXR files are a linear format.
When colour mapping and gamma was selected, the image was gamma encoded during rendering.
To remove this and return the colours to linear colour space we must invert the gamma curve. The inverse of 2.2 is .4545.
If you don’t and save as 1.0, no change will be made.
Photoshop recognises an EXR is a linear format, and displays it in sRGB colour space to brighten it up and display it correctly.
If the file has already been brightened, it will be brightened twice and look washed out.
Photoshop has just done what it’s been told. It doesn’t know you added a gamma encoding while rendering!

Post Gamma Method

Set the System gamma to input 2.2, output 2.2.
The easiest way to do this is to open a file with these settings and adopt them.

Vray Frame Buffer:
Make sure the sRGB preview is Enabled.

Gamma/LUT Setup:
(Menu bar/Rendering/Gamma/LUT Setup)
Tick Enable Gamma/LUT Correction
Gamma 2.2
Do not tick affect colour selectors.
Tick Affect material editor.

Vray Render Dialogue:
Colour mapping tab:
Set the gamma value to 2.2
Mode: Set to colour mapping only (no Gamma)

Saving LDR files

If you have the system output gamma set as 2.2, 3Ds Max will use this as it’s automatic LDR gamma output.
When saving jpg, tga or other LDR images just set to automatic.

Saving Floating point formats

EXR: select override, type .4545
Max also knows that floating point images need no gamma encoding. When saving an exr image, set automatic and Max will save as a 1.0 output.

Diffuse Colours

How to import diffuse textures and how to set flat colours

How to change the system gamma

Post Gamma Method (Gamma is previewed in frame buffer)

Open the input 2.2, Output 2.2 Max file.
Select file gamma. This sets the system gamma.
Open Your scene and select Keep the system’s gamma and LUT settings.
(Input 2.2, Output 2.2)

Pre Gamma Method (Gamma is Burned in while rendering)

Open the input 2.2, Output 1.0 Max file.
Select file gamma. This sets the system gamma.
Open Your scene and select the Keep the system’s gamma and LUT settings.
(Input 2.2, Output 1.0)

  • Vray.

    Linear workflow in 3Ds Max & Vray.

    Quickly set up linear workflow.

    FIND OUT HOW

  • Vray & 3Ds Max.

    Troubleshooting.

    No matter how experienced you are in the world of 3D, sometimes things just go wrong… This oughta help though!.

    FIND OUT HOW