Versions Compared

Key

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

This page contains information about the V-Ray TexUserScalar node.


Overview

...


 

Section
Column
width50%

The V-Ray User Float texture allows the user to read and return a single number value from the User-Defined properties of the currently shaded object as a result. This can be useful if the same material or texture is applied to several objects in the scene, but we want to control some of its aspects (i.e. material glossiness, or a blend between two other textures inside a Mix texture etc.) with User-Defined properties.

 

UI path: ||mat Network|| > V-Ray > Texture: Utility > V-Ray User Float

 
Column
width5%


Column
width45%

  Image Removed

 

 

 

 

Image Added


Parameters

...

Section
Column
width50%

Attribute – Specifies the name of the user attribute that is looked up and returned from this shading node.

Default Value  Specifies the value to return if the user attribute is not found on the shaded object.

Attribute Priority – Specifies the attribute priority of V-Ray User Float.

User Attribute
Map Channel

Column
width5%

 


Column
width45%

Image RemovedImage Added


Examples

...

In the examples below, user attributes are assigned to different objects with different values. A V-Ray User Float texture reads the values and passes them to a shader at render time. This way we can pass different shader values that are controlled at the object level, allowing us to share the shader between all objects.

...

This example shows the format for the value of the user attribute and how it is interpreted. The V-Ray User Float texture controls the V-Ray Material Metalness parameter. A user attributed named metalness_value is used to specify different metalness values on two objects. 


The same material is applied to both objects. A V-Ray User Float texture passes the values to the shader.

 

...



Section
Column
width10%

 


Column
width35%

User attribute for the first object

 
Column
width10%


Column
width35%

User attribute for the second object

 
Column
width10%

 



Although the two objects have the same material, the metalness is determined by the user property.

 

 



Example: V-Ray User Float with V-Ray Multi ID Material

...


This example uses V-Ray User Float to control how materials from a V-Ray Multi ID Material are distributed to different objects.

Two different V-Ray Materials are linked as Material 1 and Material 2 in a V-Ray Multi ID Material. A V-Ray User Float is linked to the mtlid_gen_float slot and a user attribute named outputMaterial drives the material distribution. 


The same V-Ray Multi ID Material is assigned to two spheres and the V-Ray user User Foat texture determines how Material 1 and 2 are distributed between the spheres.

 


Section
Column
width10%

 


Column
width35%

User attribute for the first object

Column
width10%

 


Column
width35%

User attribute for the second object

Column
width10%

 

...



The left sphere received Material 1 and the right sphere received Material 2