This page contains information about the V-Ray TexUserScalar node.
|
|
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.
With the help of a user attribute we can control any scalar (float) parameter of the shader.
User attributes can be added though an Attribute Wrangle node or an Attribute Create node.
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.
|
Although the two objects have the same material, the metalness is determined by the user property.
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 Foat texture determines how Material 1 and 2 are distributed between the spheres.
|
The left sphere received Material 1 and the right sphere received Material 2