Versions Compared

Key

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

This page provides information about the Displacement in V-Ray for Revit.

 


Overview

...

Section
Column
width60%

Displacement mapping is a technique for adding detail to geometric objects 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.

The image slider on the right shows the effect of the Displacement mapping.

Column
width5%

 


Column
width35%
Before after
afterLabelenabled
beforeLabeldisabled
Panel
borderStylenone
Panel
borderStylenone

...



UI path

...

Section
Column
width5%
 

Column
width45%

Creating Displacement:

||V-Ray Asset Editor|| > Create Asset > Geometries > Displacement

||V-Ray Asset Editor|| > Geometry > Displacement

Column
width45%

Assigning Displacement:

||Appearance Manager|| > Materials tab > Add Displacement

Column
width5%

 

 

 




Workflow

...

Section
Columnfancy-bullets
widthtype40%circle
  • Create a Displacement geometry in the Asset Editor from the Geometry drop-down menu or from Create Asset > Geometries > Displacement and assign a texture to the Map slot.
    Currently, the displacement geometry is not assigned to any object in the Revit model and it is not visible during rendering.
  • In the Appearance Manager, navigate to the material that needs displacement.
  • From the Vthe V-Ray drop-down menu next to it, select Displacement. A grey dot indicates that the Displacement is assigned to that material. All objects that have the material assigned to them also acquire the Displacement.

 

UI Text Box
typetip

Displacement assigned to a material can be disabled from the Displacement (Image Modified) icon in the Appearance Manager when the material is selected.

Section
Column
width5%15%


Column
width70%


Image Added

 

Image Removed
Column
width55%
15%




Parameters

...

Section
Column
width60%

Enabled – Turns on/off displacement.

Mode/Map – Specifies the mode in which the displacement is rendered:

Normal Displacement – Takes the original surface geometry and subdivides its triangles into smaller sub-triangles which are then displaced.
2D Displacement – 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 has valid UV coordinates. You cannot use this method for 3D procedural textures or other textures that use object or world coordinates.

Amount – Specifies the amount of displacement. A value of 0.0 means the object appears unchanged. Higher values produce a greater displacement effect. This value can also be negative, in which case the displacement pushes geometry inside the object.

Shift – Specifies a constant to be added to the displacement map values, effectively shifting the displaced surface up and down along the normals. This value can be either positive or negative. See the 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. See the Keep Continuity example below.

View Dependent – When enabled, the Edge Length parameter determines the maximum length of a sub-triangle edge, in pixels. A value of 1.0, for example, means that the longest edge of the resulting mesh is about 1 pixel long (when projected on the screen). When disabled, the Edge Length value is the maximum sub-triangle edge length in world units.

Edge Length – Determines the quality of the displacement. The behavior of this parameter depends on the View Dependent parameter above. Note that each triangle of the original mesh is divided into sub-triangles. More sub-triangles mean more detail in the displacement, slower rendering times and more RAM usage. Less sub-triangles mean less detail, faster rendering and less RAM. See the Edge Length example below.

Max Subdivs – Controls the maximum number of sub-triangles generated for every triangle of the original mesh. The maximum number of sub-triangles can be calculated by squaring this value. For example, a value of 256 means that at most 256 x 256 = 65536 sub-triangles are generated for any given original triangle. It is not a good idea to increase this value much higher than 256. If that's required, it will be better to tessellate the original mesh.

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 normal map based on the displacement map, to compensate for details not captured by the actual displaced surface.

Water Level – Turns on/off water level.

Level Height – Specifies a value below which the geometry is clipped. See the Height Level example below.

 
Column
width5%


Column
width35%

 


Anchor
shift
shift

...

Example: Shift

 


Note that the Shift parameter is an absolute value in world units. If you change the Amount, you will probably need to adjust the Shift too.

Section
Column
width30%

 


Column
width40%
Image slider
minLabel-10.0
startIndex2
maxLabel10.0
Panel
borderStylenone

Shift = -10.0

Panel
borderStylenone

Shift = -5.0

Panel
borderStylenone

Shift = 0.0

Panel
borderStylenone

Shift = 5.0

Panel
borderStylenone

Shift = 10.0

Column
width30%

 

 



Anchor
water
water

...

Example: Level Height 

...

The Level Height 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 Level Height reaches Amount + Shift, all geometry is clipped.

Section
 
Column
width30%


Column
width40%
Image slider
minLabel0.0
startIndex2
maxLabel5.0
Panel
borderStylenone


Level Height
 0.0 (no clipping)

Panel
borderStylenone


Level Height
 1.25 

Panel
borderStylenone


Level Height
 2.5 

Panel
borderStylenone


Level Height
 3.75 

Panel
borderStylenone

Level Height = 5.0 (all geometry is clipped)
Column
width30%

 

 



Anchor
edgeLength
edgeLength
 

...

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.

Section
Column
width15%
 

Column
width60%
Image slider
minLabel0.5
startIndex2
maxLabel10.0
Panel
borderStylenone

Edge Length = 0.5

Panel
borderStylenone

Edge Length = 1.0

Panel
borderStylenone

Edge Length = 2.0

Panel
borderStylenone

Edge Length = 5.0

Panel
borderStylenone

Edge Length  = 10.0

Column
width15%

 

...



Anchor
Keep
Keep

...

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 also helps to produce a smoother result across material ID boundaries for objects that have been assigned MultiSubObject materials.

 


Section
Column
width30%

 


Column
width40%
Image slider
startIndex1
Panel
borderStylenone

No displacement

Panel
borderStylenone

Keep Continuity = disabled

Panel
borderStylenone

Keep Continuity = enabled

Column
width30%

 

...



Notes

...

Fancy Bullets
typecircle
  • When a Displacement geometry is added to the material of a Scatter guest, it is ignored for the scattered instances. The Displacement is also ignored for the original instance geometry added as a guest.