Versions Compared

Key

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

This page gives information about the Z-Depth Render Element. 

 


Overview

...

Section
Column
width60%

The Z-Depth Render Element is a grayscale image that renders each pixel based on its distance from the camera in the view. It provides information about each object's distance from the camera in the current view. Each pixel representing the object is evaluated for distance individually; different pixels for the same object can have different grayscale values. In this render element, objects (or portions of objects) closest to the camera appear as black while those furthest away appear white. Objects between the furthest and nearest points are rendered in varying shades of gray. The lighter the gray, the further away an object pixel is from the camera. (Image is inverted.)

The most common usage of the Z-Depth Render Element is as a control for depth of field in the composite. Depth of field can be challenging to do correctly within 3ds Max, requiring many tweaks and re-renders; using the Z-Depth Render Element in a composite is usually much faster, and allows easier and faster adjustment than trying to get it exactly right within the render from 3ds Max. 


 
UI Expand
titleUI Path: ||Render Setup window|| > Render Elements tab > Add button > VayZDepth
VRayZDepth


 
Column
width5%

Column
width35%

...


Parameters

...

Section
Column
width60%

This render element is enabled through the Render Elements tab of the Render Setup window in 3ds Max and displays its parameters in a rollout at the bottom of the window:

VRayVFB – When enabled, the Z-Depth pass appears in the V-Ray Frame Buffer.

Deep output – Specifies whether to include this render element in deep images.

Zdepth use camera clip boundaries – Specifies whether to use to camera clip boundaries as the minimum and maximum Z-Depth distance. Enabling this option disables the Zdepth min and Zdepth max parameters.

Zdepth min – Objects up to this distance from the camera render as black. This option is available only when Zdepth use camera clip boundaries is disabled.

Zdepth max – Objects further than this distance from the camera render as white. This option is available only when Zdepth use camera clip boundaries is disabled.

Clamp zdepth – Clamps the Z-Depth colors to a linear 0-1 range.

Invert zdepth – Inverts the colors of the Z-Depth render element. Objects closest to the camera render as white, while those furthest away are black.

Don't filter environment – When enabled, only outlines of overlaying objects are filtered.

 
Column
width5%


Column
width35%

 

Z-Depth Minimum and Maximum

...

The Z-Depth Render Element parameters for minimum and maximum depth, Zdepth min and Zdepth max, can be set to various values to provide different ranges of depth in the render element. In these examples, Clamp zdepth is enabled and Invert zdepth is disabled.

Section
 
Column
width25%


Column
width50%
Image slider
Panel
borderStylenone

Zdepth min = 0cm, Zdepth max = 600cm

Panel
borderStylenone

Zdepth min = 0cm, Zdepth max = 1000cm

Panel
borderStylenone

Zdepth min = 0cm, Zdepth max = 3500cm

Panel
borderStylenone

Zdepth min = 400cm, Zdepth max =3500cm

Panel
borderStylenone

Zdepth min = 600cm, Zdepth max = 3500cm

 
Column
width25%


Invert zdepth

...

The black and white values in the Z-Depth Render Element can be inverted by enabling the Invert zdepth option.

...

The Z-Depth Render Element is useful for adding Depth of Field to the final image in post production using a compositing application, without the need for re-rendering. It can also be used to create basic fog by overlaying it on the composite with Add mode or Screen mode, with color correction as needed. 


Section
 
Column
width30%


Column
width40%
Image slider
startIndex1
Panel
borderStylenone

Depth of field applied to composite using Z-Depth Render Element

Panel
borderStylenone

Original Beauty Composite

Panel
borderStylenone

Basic fog applied to composite using Z-Depth Render Element

 
Column
width30%