Versions Compared

Key

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

...

Section
Column
width60%

The Sampler Info Render Element is a color image that provides information about the scene, with the choice to show any of various aspects as color blocks. This render element provides information about various aspects of the shaded points such as position, normal, bump normal, reflection/refraction vectors and UVW coordinates. This render element can be used either for world position passes or normal passes. It extracts particular information about the scene, converting the gathered information into RGB data for use in compositing.

Column
width5%

 

Column
width35%

Image Removed

 

 

...


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

Image Added

||Render Setup window||  > Render Elements  tab  > Add  button  > VRaySamplerInfo

section

20%
Column
width
5%

 

Column
width
60%

Image Removed

Column
width20%

 

 

...

35%

Image Added


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 – VRayVFB – Enables the render element inside the V-Ray frame bufferFrame Buffer.

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

Type  Controls the type of render element produced by VRaySamplerInfo:

Point  The XThe X, Y, and Z coordinates Z coordinates of the point are converted to RGB data according to the coord system that data according to the Coord system that is set. This outputs This outputs a Position Pass for use in compositing.
Normal vector 
 The – The direction of the normal at the particular shaded point according to which coord Coord system is set.
Reflection vector  Commonly used
for adjusting for adjusting reflections in the composite.
Refraction vector 
Commonly Commonly used for adjusting for adjusting refractions in the composite.
UVW
coordinates – Extracts coordinates – Extracts the UVW coordinates of the object at the particular shaded point.  This can be used to apply another texture at a composite level.
Normal vector with bump mapping 
–  Produces the bump normal according to the coord Coord system that is set.
Backward occlusion  The red and green components of this render element represent the screen position of the shaded point at the beginning of the motion-blurred frame, while the blue component represents camera occlusion at the beginning of the motion-blurred frame. Together with the Forward occlusion
 render  render element, this can be used for denoising and/or post-process motion blur.
Forward occlusion  The red and green components of this render element represent the screen position of the shaded point at the end of the motion-blurred frame, while the blue component represents camera occlusion at the end of the motion-blurred frame. Together with
the the Backward occlusion render  render element, this can be used for denoising and/or post-process motion blur.
Integer ID from node user attribute  Extracts any integer node user property into an integer render element. Can be used as an extended Object ID.
Float number from node user attribute 
Extracts Extracts any floating-point node user property into a single-channel floating-point render element. Can be used to extract additional masks.
Tangent vector in object space –  Displays tangent vector according to the Object space.
Bitangent vector in object space –
Displays Displays bitangent vector according to the Object space.

Point multiplier –  Acts as a multiplier when typeType is set to Point.

Refract IOR  Sets the index of refraction when Refraction vector is set as the type Type.

UVW channel – The – The UVW mapping channel used when the typeType is set to UVW coordinates.

UVW mode –  Specifies what happens to UVW values outside the 0.0-1.0 range of the unit texture square:

Normal –  Stores the UVW coordinates without modification.
Clamp 
–  UVW coordinates above 1.0 are clamped to 1.0, and values below 0.0 are clamped to 0.0.
Tile  Wraps the UVW coordinates to the unit texture square.

    Coord system  Controls  – Controls the coordinate system used:

World – X– X, Y, and Z coordinates (in world space) of the point are converted to RGB data.
Object  X, Y, and Z coordinates (in object space) of the point are converted to RGB data.
Camera 
–  X, Y, and Z coordinates (in camera space) of the point are converted to RGB data.
relative – Relative  X, Y, and Z coordinates in the object space of the relative Relative node are converted to RGB data.

Relative node  When coord Coord system is set to relativeRelative, this specifies the scene node relative to which the point/vector data is stored.Output 

Output – Controls the way data is stored in the render element when the type is a normal vector, or a reflection/refraction direction:

Vector (signed)  Values are stored directly without modification, including negative components.
Color (unsigned)  Values are scaled down by 0.5 and offset by 0.5 so that (0, 0, 0) maps to (0.5, 0.5, 0.5), (-1, -1, -1) maps to (0, 0, 0) and (1,1,1) maps to (1,1,1). This avoids negative values which might be necessary for some compositing packages.

User attribute  Determines which user attribute to connect to when when Integer ID from node user attribute or  or Float number from node user attribute are selected as type Тype.

Occlusion bias –  Controls the positional bias of the the Backward occlusion Forward occlusion types  types in order to prevent incorrect self-occlusion.

Column
width5%

 

Column
width35%
Image Removed

Image Added

  

Common Uses

...

The VRaySamplerInfoTex texture extracts particular information about the scene. It then converts the gathered information into RGB data that can be used for compositing. Here are examples of the types of data that can be extracted, and how that data is displayed in the render element.

The following examples have the coordinates system set to world space.

Section
Column
width10%30%
 

Image Removed
Sampler Info Render Element
with type set to Normal vector

Column
width40%

Image Removed
Sampler Info Render Element
with type set to Point (world space)

 

Column
width40%
Column
width10%

 

Section
Column
width10%

 

Column
width40%

Image Removed
Sampler Info Render Element
with type set to Reflection vector (world space)

Column
width40%

Image Removed
Sampler Info Render Element
with type set to Refraction vector (world space)

Column
width10%

 

Section
Column
width10%

 

Column
width40%

Image Removed
Sampler Info Render Element
with type set to UVW coordinates

 

Column
width40%

Image Removed
Sampler Info Render Element with type set to
Normal vector with bump mapping

 

Column
width10%

 

 

Image slider
Panel
borderStylenone

Image Added

Point Type in world space

Panel
borderStylenone

Image Added

Normal vector in world space

Panel
borderStylenone

Image Added

Reflection vector Type in world space

Panel
borderStylenone

Image Added

Refraction vector Type in world space

Column
width30%

 

 

 

...

The following examples have the coordinate system set to object space. 

Section
Column
width10%30%

 

Image Removed
Sampler Info Render Element with type set to
Reflection vector (object space)

Column
width40%

Image Removed
Sampler Info Render Element
with type set to Point (object space)

 

Column
width40%
Column
width10%

 

Section
Image slider
Panel
borderStylenone

Image Added

Point Type in object space

Panel
borderStylenone

Image Added

Reflection vector Type in object space

Panel
borderStylenone

Image Added

Refraction vector Type in object space

Column
width30%

 

Column
width10%

 

Image Removed
Sampler Info Render Element with type set to
Refraction vector (object space)

10%
Column
width80%
Column
width

 

 

...

The following examples have the coordinates system set to camera space.

 

Section
Column
width10%30%

 

Column
width40%

Image Removed
Sampler Info Render Element with type set to Point (camera space)

 

Column
width40%

Image Removed
Sampler Info Render Element with type set to Reflection vector (camera space)

 

Column
width10%

 

Section
Image slider
Panel
borderStylenone

Image Added

Point Type in camera space

Panel
borderStylenone

Image Added

Reflection vector in camera space

Panel
borderStylenone

Image Added

Refraction vector in camera space

Column
width10%

 

Column
width40%

Image Removed
Sampler Info Render Element with type set to Refraction vector (camera space)

 

10%
Column
width40%

Image Removed Sampler Info Render Element with type set to Refraction vector (relative space)

 

30%

 

Column
width

 

 

...

The following examples have the coordinates system set to relative space.

 

Section
Column
width10%30%

 

Column
width40%

Image Removed

Sampler Info Render Element with type set to Point (relative space)

 

Column
width40%

Image Removed

Sampler Info Render Element with type set to Reflection vector (relative space)

 

Image slider
Panel
borderStylenone

Image Added

Point Type in relative space

Panel
borderStylenone

Image Added

Reflection vector Type in relative space

Panel
borderStylenone

Image Added

Refraction vector Type in relative space

10%
Column
width30%

 

Column
width

 

 

...


Example: Re-texturing in composite

...

Using the VRaySamplerInfo Render Element makes it is possible to apply a new texture to an already rendered still or sequence via setting its type Type to UVW coordinates. This then enables the creation of what effectively amounts to a new Diffuse Filter Render Element which can then be used in a composite, enabling a change of texture to be easily made. It is worth noting that any UV stretching on the model will carry carries through into the UVW pass created by VRaySamplerInfo as can be seen in the examples below.

 

Section
Column
width10%

 

Column
width40%

Image Removed
The Sampler Info with type set to UVW coordinates (uvw mode = normal)

 

Column
width40%

Image Removed
Beauty render prior to re-texturing in composite

 

Column
width10%

 

the VRaySamplerInfo. See the render before and after compositing.

Before after
darktrue
Panel
borderStylenone

Image Added

Panel
borderStylenone

Image Added

Section
Column
width10%

 

Column
width40%

Image Removed
New texture image applied in composite.
(This effectively creates a new Diffuse Filter Pass)

 

Column
width40%

Image Removed
Re-textured Beauty render (done purely at a composite level)

 

10%
Column
width

 

 

Anchor
uvwTypes
uvwTypes

...

 

Supported UVW Coordinate Types

...

The table below provides some details on the supported UVW coordinate types within the Sampler Info Render Element. Pass types such as Normal, Normal vector with bump mapping, World coordinates and Point can be used to relight a scene at a composite level. While UVW coordinates and Object coordinates can be used to re-texture items in a scene in composite. The Reflection vector type can be used to adjust or remap reflections, similarly the Refraction vector can do the same at a composite level for refractions. Some types such as the Forward occlusion and Backwards occlusion can be used together for denoising and/or post-process motion blur while the Shading incidence type can be used as a mask in composite.  

The Integer ID from node user attribute can be used as  an an extended Object ID and the Float number from node user attribute can used to extract additional masks.  

...

Pass TypeCoord. SystemUVW ModeOutputV-Ray RenderV-Ray GPU
PointWorld  (tick)(tick)
PointObject  (tick)(error)
PointCamera  (tick)(tick)
PointRelative  (tick)(error)
NormalWorld Vector (signed) or Color (unsigned)(tick)PARTIAL
NormalObject Vector (signed) or Color (unsigned)(tick)(error)
NormalCamera Vector (signed) or Color (unsigned)(tick)PARTIAL
NormalRelative Vector (signed) or Color (unsigned)(tick)PARTIAL
ReflectionWorld Vector (signed) or Color (unsigned)(tick)(error)
ReflectionObject Vector (signed) or Color (unsigned)(tick)(error)
ReflectionCamera Vector (signed) or Color (unsigned)(tick)(error)
ReflectionRelative Vector (signed) or Color (unsigned)(tick)(error)
RefractionWorld Vector (signed) or Color (unsigned)(tick)(error)
RefractionObject Vector (signed) or Color (unsigned)(tick)(error)
RefractionCamera Vector (signed) or Color (unsigned)(tick)(error)
RefractionRelative Vector (signed) or Color (unsigned)(tick)(error)
UVW coordinates Normal (tick)(tick)
UVW coordinates Clamp (tick)(tick)
UVW coordinates Tile (tick)(error)
Normal vector with bump mappingWorld Vector (signed) or Color (unsigned)(tick)(error)
Normal vector with bump mappingObject Vector (signed) or Color (unsigned)(tick)(error)
Normal vector with bump mappingCamera Vector (signed) or Color (unsigned)(tick)(error)
Normal vector with bump mappingRelative Vector (signed) or Color (unsigned)(tick)(error)
Backwards occlusion   (tick)(error)
Forward occlusion   (tick)(error)
Integer ID from node user attribute   (tick)(tick)
Float number from node user attribute   

 

...

(tick)(tick)