This page provides information on the V-Ray GeomDisplacedMesh node, which controls displacement on meshes.
Displacement mapping is a technique for adding detail to your scene geometry without having to model it first. The concept is very similar to bump mapping. However, bump mapping is a shading effect that only changes the appearance of a surface, while displacement mapping actually modifies the surface.
There are two ways to add displacement to an object with V-Ray Displacement. One is through material assignment and the other - directly to the geometry. For detailed information, visit the Displacement Tutorial page.
||mat Network|| > V-Ray > Geometry > V-Ray Displacement
||Select object|| > V-Ray Shelf > Displacement Properties
||out Network|| > V-Ray Render Elements node > V-Ray > Geometry > V-Ray Displacement
Main options when Displacement is created in the mat Network.
Main options when Displacement is created in the obj Network
Displacement Override – This option is available only when displacement is added as Displacement Property to an object. When enabled, it allows displacement override to the whole object with the properties specified in the same tab.
Texture – Specifies a displacement texture
Type – Specifies the mode in which the displacement is rendered.
Normal – Takes the original surface geometry and subdivides its triangles into smaller sub-triangles which are then displaced. It can be applied for arbitrary displacement maps with any kind of mapping.
2D – Bases the displacement on a texture map that is known in advance. The displaced surface is rendered as a warped height-field based on that texture map. The actual raytracing of the displaced surface is done in texture space, and the result is mapped back into 3D space. The advantage of this method is that it preserves all the details in the displacement map. However, it requires that the object have valid texture coordinates. You cannot use this method for 3D procedural textures or other textures that use object or world coordinates. The displacement map can take any values.
Vector – If using a displacement texture that is not grayscale, V-Ray converts it to grayscale before rendering the displaced geometry. This mode allows V-Ray to use the Red, Green, and Blue channels of the displacement texture to displace the geometry in the U and V directions in addition to the direction of the face normal.
Vector (Absolute) – A vector-type displacement mode in which the texture is interpreted as 0.5-based tangent space displacement map.
Vector (Object) – Only meaningful when a VRayPtex is used for displacement, where the texture values represent 0-based displacement in object space. If mesh information is stored in the Ptex file, V-Ray can also displace correctly mesh deformations.
Flip Green / Blue Channels – When enabled, the Green and Blue channels of the supplied texture map are swapped.
Generate – Specifies how the resulting triangles of the displacement algorithm are inserted into the rayserver.
On the Fly – Dynamic
Pre-Tesselated – Static
Amount –The amount of displacement for white areas of the displacement map. If Use Global Settings is enabled, this value is multiplied by the global displacement Amount option. A value of 0.0 means the object appears unchanged. Higher values produce a greater displacement effect. This can also be negative, in which case the displacement pushes geometry inside the object.
Shift –Specifies a constant which is added to the displacement map values, effectively shifting the displaced surface up and down along the normals. This can be either positive or negative. For more information, see the Displacement Shift example below.
Keep Continuity – When enabled, V-Ray tries to produce a connected surface. Use it when you get splits (usually around sharp edges) in the displaced geometry. For more information, see the Keep Continuity example below.
Water Level – Geometry below this displacement level threshold is clipped away. This can be used for clip mapping a displacement map value below which geometry is clipped. For more information, see the Clip Mapping example below.
Cache Normals – When enabled, V-Ray generates and saves information about the normal of each newly generated vertex. This requires additional memory but speeds up the shading calculations during rendering. Please see the Displacement Tab to improve output result.
This option is always On when rendering on the GPU. This is not recommended with low displacement settings.
Use Bounds – When enabled, allows the user to set the minimum and maximum values for the displacement texture. For more information, see the Texture Boundaries example below.
Min/Max Bound – These two options allow you to specify custom boundaries for the displaced geometry when Use Bounds is enabled. By default is limited to values between 0 and 1.
View Dependent – Determines if view-dependent tessellation is used. When enabled, Edge Length determines the maximum length of a subtriangle edge, in pixels. A value of 1.0 means that the longest edge of each subtriangle is about one pixel long when projected on the screen. When View-dependent is off, Edge length is the maximum subtriangle edge length in world units.
Edge Length – The maximum length of a subtriangle edge after subdivision. This affects the degree of subdivision before displacement, which in turn affects the quality of the displacement itself. Each triangle of the original mesh is subdivided into a number of subtriangles. More subtriangles mean more detail in the displacement, slower rendering times and more memory usage. Less subtriangles mean less detail, faster rendering and less memory used. Units used for this parameter depend on the View Dependent parameter. For more information, see the Edge Length example below.
Max Subdivisions – Controls the maximum number of subtriangles generated from any one triangle of the original mesh. The square of this value is used. For example, a value of 256 means that at most 256 x 256 = 65536 subtriangles will be generated for any given original triangle. It is recommended that this value not be increased a great deal over the default value of 256. If you need to use higher values, it is better to first tessellate the original mesh itself into smaller triangles before starting the displacement process.
Tight Bounds – When enabled, causes V-Ray to compute more precise bounding volumes for the displaced triangles, leading to slightly better rendering times.
In GPU mode where Cache Normals is always enabled, lowering the Edge length or increasing the Max. subdivs will help to achieve results more closely in line to CPU mode.
Render As Subdivision – When enabled, the object is subdivided during rendering.
Preserve Map Borders – Specifies how to handle subdivisions of UV coordinates at UV seams. The possible values are:
Not Set – The default value when the value has not been set.
None – UVs are always subdivided regardless of whether they are on a UV seam or not
Internal – Only preserve UVs if they are on an internal UV seam;
All – Does not subdivide UVs on UV seams.
Classic Catmull-Clark – When this option is enabled, V-Ray uses the Classic Catmull-Clark method for subdividing the mesh instead of the hybrid one used by default. This option should be enabled only if the mesh is composed entirely of rectangular faces or it does not work.
Resolution – Determines the resolution of the displacement texture used by V-Ray. If the texture map is a bitmap, it would be best to match this resolution to the size of the bitmap. For procedural 2D maps, the resolution is determined by the desired quality and detail in the displacement. Note that V-Ray also automatically generates a normals map based on the displacement map, to compensate for details not captured by the actual displaced surface.
Precision – Related to the curvature of the displaced surface; flat surfaces can do with a lower precision (for a perfectly flat plane you can use a value of 1), more curved surfaces require higher values. If the precision is not high enough you can get dark spots ("surface acne") on the displacement. Lower values compute faster.
Filter Texture – When enabled, the texture map is filtered before the actual displacement takes place.
Filter Blur – Specifies the amount of blur that is applied to the texture before the displacement takes place.
Multi-Tile – Enables or disables support for tiled textures (UDIM/UVTILE) when generating 2d displacement.
Example: Vector Displacement
This example shows the effect of the Vector (vector displacement) option in more detail.
The first image shows complex geometry on the left. This geometry was used to create a vector displacement map. The second image shows the resulting displacement map, where the red, green and blue components define displacement vectors in the texture UVW space. The final image shows the vector displacement map applied on another object through the Displacement material node.
A piece of complex geometry, and a simple version
with a VRayVectorDisplBake material.
The displacement map, computed by texture baking.
The result is saved into an .exr file (a .png file is shown here).
The displacement map applied on a different geometry through
the Displacement node with vector displacement.
Example: Displacement Shift
Note that the Displacement Shift parameter is an absolute value in world units. If you change the Displacement Amount, you will probably need to adjust the Displacement Shift too.
Example: Edge Length
This example shows the effects of increasing the Edge length parameter. In this example View-dependent is enabled, so Edge length is expressed in pixels. In the examples, the closeup view is a blow-up rather than a zoomed view. This means that Edge length in the closeup view refers to pixels in the original image, not the blow-up rendering.
The image below was rendered with a V-Ray Edges map in the Diffuse slot of the material to show the original triangles of the mesh. Additionally, we turned on the Faceted option in the VRayMtl. V-Ray not only smooths the surface normals, but also automatically applies a normals map that represents the normal of the perfect displaced surface, which makes the surface look a lot more detailed than it actually is.
Example: Keep Continuity
The Keep Continuity option is useful for objects with disjoint normals on neighboring triangles, usually because of different smoothing groups. In the middle image below you can see the edge splits produced by disjoint normals. Using the Keep Continuity option avoids this problem. This option will also help to produce a smoother result across material ID boundaries for objects with multiple materials.
Example: Clip Mapping
The Water level parameter is absolute in world units. For this example, Amount is set to 5.0 and Shift is set to 0.0. Note that when Water level reaches Amount + Shift, all geometry is clipped.
Example: Texture Boundaries
This example shows a plane mapped with a displacement map that has negative values. With the default boundaries for the displacement (from 0 to 1) we are unable to see the geometry displaced in the negative direction. However, once we set Min Bounds and Max Bounds to -1 and 1 respectively, we can see the displaced geometry in both the positive and negative direction.