This page introduces you to the VRayMtl, which is the major building block for most shading networks in V-Ray.

 

Page Contents

 

Overview


The VRayMtl is a very versatile material that allows for better physically correct illumination (energy distribution) in the scene, faster rendering, and more convenient reflection and refraction parameters. This material can be easily set up to simulate a huge variety of surfaces from plastics to metals to glass and more by adjusting a handful of parameters.

Furthermore, with the VRayMtl you can apply different texture maps, control the reflections and refractions, add bump and displacement maps, force direct GI calculations, and choose the BRDF for how light interacts with the surface material.

 

 


Image courtesy of Mathew Monro

 

 


 

UI Paths:

||Hypershade|| > Create panel > VRay section > VRay Mtl


||Create Render Node window|| > VRay section > VRay Mtl

 

||V-Ray Shelf|| > Right-click to Create V-Ray Materials button > VRay Mtl

 

 


Swatch Properties


This section allows you to control the swatch for the VRayMtl material.

 

 

 

Auto update – When enabled, the view in the swatch will update automatically every time one of the VRayMtl properties is changed. When the check box is not selected the swatch will not update automatically but you will be able to update it manually with the Update button.

Max resolution – Determines the maximum resolution of the swatch.

Update – When clicked, forces an update of the swatch.

 

Basic Parameters






Diffuse Color – The diffuse color of the material. Note: the actual diffuse color of the surface also depends on the reflection and refraction colors.

Amount – A multiplier for the diffuse color.

Opacity Map – Assigns opacity to the material where white is completely opaque and black is completely transparent. You can also assign a map by clicking the check board button. This way you can create a material that has a non-uniform opacity.

Opacity mode – Controls how the opacity map works. For more information, see the Opacity mode parameter example below.

Normal – The opacity map is evaluated as normal: the surface lighting is computed and the ray is continued for the transparent effect. The opacity texture is filtered as normal.
Clip – The surface is shaded as either fully opaque or fully transparent depending on the value of the opacity map (i.e. without any randomness). This mode also disables the filtering of the opacity texture. This is the fastest mode, but it might increase flickering when rendering animations.
Stochastic
– The surface is randomly shaded as either fully opaque or fully transparent so that on average it appears to be with the correct transparency. This mode reduces lighting calculations but might introduce some noise in areas where the opacity map has gray-scale values. The opacity texture is still filtered as normal

Roughness Amount – Used to simulate rough surfaces or surfaces covered with dust (for example, skin, or the surface of the Moon).

Self-Illumination – The self-illumination color of the material. A texture map can be used for the self-illumination color by clicking on the check board box next to the color slider.

Self-Illumination GI – When enabled, the self-illumination affects global illumination rays and allows the surface to cast light on nearby objects. Note, however, that it may be more efficient to use area lights or VRayLightMtl material for this effect.

Compensate Exposure – When enabled, the intensity of the Self-Illumination will be adjusted to compensate the exposure correction from the VRayPhysicalCamera.

 

 


 

 

Example: Opacity mode parameter

 

 


Opacity mode = Normal
Because the opacity texture is filtered the result is nice and smooth but very slow.

 


Opacity mode = Stochastic
The texture is still filtered, so the result is smooth but render times are greatly improved.

 


Opacity mode = Clip
The texture is forced to black or white; the render time is very fast, but the result is sharper which may increase flickering in animation.

 

 

 

The renders below show a blow-up of the tree to better show the effect of the different modes. Note that in the first two renders the opacity is blurry because of the texture filtering.

 


Opacity mode = Normal
Because the texture is filtered, this makes the normal-sized render smoother and reduces flickering in animation, but the render time is very slow.

 


Opacity mode = Stochastic
The texture is still filtered, which keeps the normal-sized render smooth, and the render time is much better.

 


Opacity Mode = Clip
Because the opacity map is forced to either full black or white, the result is sharp. The render time is very good, but the increased sharpness can increase flickering in animations.

 

 

 


 

Reflection


The BRDF parameter determines the type of the highlights and glossy reflections for the material. This parameter has an effect only if the reflection color is different from black and reflection glossiness is different from 1.0.

 

 

 

BRDF Type – Determines the type of BRDF (the shape of the highlight):

Phong – Phong highlight/reflections
Blinn – Blinn highlight/reflections
Ward – Ward highlight/reflections
GGX – GGX Microfacet highlight/reflections

For more information, see The BRDF Type example below.

Reflection Color – Reflection color. Note that the reflection color dims the diffuse surface color. For more information, see The Reflection Color Parameter example below.

Amount – A multiplier for the reflection color.

Lock highlight and reflection glossiness – When disabled, the user can enter different values for the highlight glossiness and Reflection glossiness. However, this will not produce physically correct results.

Highlight Glossiness – Determines the shape of the highlight on the material. Normally this parameter is locked to the Reflection glossiness value in order to produce physically accurate results.

Reflection Glossiness – Controls the sharpness of reflections. A value of 1.0 means perfect mirror-like reflection; lower values produce blurry or glossy reflections. Use the Reflection Subdivs parameter below to control the quality of glossy reflections. For more information, see The Reflection Glossiness Parameter example below.

Reflection subdivs – Controls the quality of glossy reflections. Lower values will render faster, but the result will be noisier. Higher values take longer but produce smoother results. Note that this parameter is available for changing only when Use local subdivs is enabled in the DMC Sampler Settings.

Use Fresnel – When enabled, makes the reflection strength dependent on the viewing angle of the surface. Some materials in nature (glass etc) reflect light in this manner. Note that the Fresnel effect depends on the index of refraction as well.

Glossy Fresnel – When enabled, uses glossy fresnel to interpolate glossy reflections and refractions. It takes the Fresnel equation into account for each "microfacet" of the glossy reflections, rather than just the angle between the viewing ray and the surface normal. The most apparent effect is less brightening of the grazing edges as the glossiness is decreased. With the regular Fresnel, objects with low glossiness may appear to be unnaturally bright and "glowing" at the edges. The Glossy Fresnel calculations make this effect more natural.

Lock Fresnel IOR To Refraction IOR – Allows the user to unlock the Fresnel IOR parameter for finer control over the reflections.

Fresnel IOR – The IOR to use when calculating Fresnel reflections. Normally this is locked to the Refraction IOR parameter, but you can unlock it for finer control. For more information, see The Use Fresnel Option example below.

GGX tail falloff – Controls the transition from highlighted areas to non-highlighted areas when the BRDF Type is set to GGX.

 


 

Example: The BRDF Type


This example demonstrates the differences between the BRDFs available in V-Ray. Note the different highlights produced by the different BRDFs. The Reflection Glossiness is set to 0.8.

 

 


BRDF type is Phong

 


BRDF type is Blinn

 


BRDF type is Ward

 


BRDF type is GGX

 

 

 


 

Example: The Reflection Color Parameter


This example demonstrates how the Reflection color parameter controls the reflectivity of the material. Note that this color also acts as a filter for the diffuse color (e.g. stronger reflections dim the diffuse component). Use Fresnel is disabled.

 

 


Reflection color is black (0, 0, 0)

 


Reflection color is medium gray (128, 128, 128)

 


Reflection color is white (255, 255, 255)

 

 

 


 

Example: The Reflection Glossiness Parameter


This example demonstrates how the Reflection glossiness and highlight glossiness parameters control the highlights and reflection blurriness of the material. The Reflection Color is white and Use Fresnel is enabled.

 

 


Reflection/highlight Glossiness is 1.0
(perfect mirror reflections)

 


Reflection/highlight glossiness is 0.8

 


Reflection/highlight glossiness is 0.6

 

 

 


 

Example: The Use Fresnel Option


This example demonstrates the effect of the Use Fresnel option. Note how the strength of the reflection varies with the IOR of the material. For this example, the Reflection color is pure white (255, 255, 255).

 

 


Fresnel is off

 


Fresnel is on, IOR is 1.3

 


Fresnel is on, IOR is 2.0

 


Fresnel is on, IOR is 10.0

 

 

 


 

Anisotropy


 

 

 

Anisotropy – Determines the shape of the highlight. A value of 0.0 means isotropic highlights. Negative and positive values simulate "brushed" surfaces. For more information, see The Anisotropy Parameter example below. 

Anisotropy UV coords – Allows the user to assign a placement Texture node and change its UV coordinates to control the direction of stretching of the highlights.

Anisotropy Rotation – Determines the orientation of the anisotropic effect in a float value between 0 and 1 (where 0 is 0 degrees and 1 is 360 degrees). For more information, see The Anisotropy Rotation Parameter example below. 

 


 

Example: The Anisotropy Parameter


This example demonstrates the effect of the Anisotropy parameter. Note how the different values stretch the reflections horizontally or vertically.

 


Anisotropy is -0.9

 


Anisotropy is -0.45

 


Anisotropy is 0.0 (no anisotropy)

 


Anisotropy is 0.45

 


Anisotropy is 0.9

 

 


 

Example: The Anisotropy Rotation Parameter


This example demonstrates the effect of the Anisotropy rotation parameter. For all the images in this example, the Anisotropy parameter itself is -0.95.

 


Anisotropy rotation is 0 (0.0 degrees)

 


Anisotropy rotation is 0.125 (45.0 degrees)

 


Anisotropy rotation is 0.25 (90.0 degrees)

 


Anisotropy rotation is 0.375 (135.0 degrees)

 


Bitmapped Anisotropy rotation

 

 


Reflection - advanced


 

 

 

Trace Reflections – Check this option to enable reflections for the material.

Reflection Exit Color – If a ray has reached its maximum reflection depth, this color will be returned without tracing the ray further.  

Max depth – The number of times a ray can be reflected. Scenes with lots of reflective and refractive surfaces may require higher values to look correct.

Dim distance On – Enables the Dim distance parameter which allows you to stop tracing reflection rays after a certain distance

Dim distance – Specifies a distance after which the reflection rays will not be traced.

Dim fall off – A fall off radius for the dim distance.

Reflect On Back Side – When disabled, V-Ray will calculate reflections for the front side of objects only. Checking it will make V-Ray calculate the reflections for the back sides of objects too.

Soften edge – Softens the edge of the BRDF at light/shadow transitions

Affect Channels – Allows the user to specify which channels are going to be affected by the reflectivity of the material.

Color Only – The reflectivity will affect only the RGB channel of the final render.
Color+alpha – Causes the material to transmit the alpha of the reflected objects, instead of displaying an opaque alpha.
All channels – All channels and render elements will be affected by the reflectivity of the material.

 

Refraction 


 

 

 

Refraction Color – Refraction color. Note that the actual refraction color depends on the reflection color as well. For more information, see The Refraction Color Parameter example below. 

Amount – This is the amount of the refraction color

Refraction Glossiness – Controls the sharpness of refractions. A value of 1.0 means perfect glass-like refraction; lower values produce blurry or glossy refractions. Use the Subdivs parameter below to control the quality of glossy refractions. For more information, see The Refraction Glossiness Parameter example below.

Refraction subdivs – Controls the quality of glossy refractions. Lower values will render faster, but the result will be noisier. Higher values take longer but produce smoother results. Note that this parameter is available for changing only when Use local subdivs is enabled in the DMC Sampler Settings.

Refraction IOR – Index of refraction for the material, which describes the way light bends when crossing the material surface. A value of 1.0 means the light will not change direction.  For more information, see The Refraction IOR Parameter example below.

Fog Color – The attenuation of light as it passes through the material. This option helps simulate the fact that thick objects look less transparent than thin objects. Note that the effect of the fog color depends on the absolute size of the objects and is therefore scene-dependent. This parameter can be mapped with a texture. It is recommended that you use a 3D texture for the purpose. For more information, see the Fog Color Parameter example below.  

Fog multiplier – The strength of the fog effect. Smaller values reduce the effect of the fog, making the material more transparent. Larger values increase the fog effect, making the material more opaque. For more information, see The Fog Color Parameter example below.

Fog bias – Changes the way the fog color is applied. Negative values make the thin parts of the objects more transparent and the thicker parts more opaque and vice-versa (positive numbers make thinner parts more opaque and thicker parts more transparent).

Affect Shadows – This parameter will cause the material to cast transparent shadows to create a simple caustic effect dependent on the refraction color and the fog color. For accurate caustic calculations, disable this parameter and instead enable Caustics in the GI tab. Simultaneous usage of both Caustics and Affects Shadows can be used for artistic purposes but will not produce a physically correct result.

 

 


 

Example: The Refraction Color Parameter


This example demonstrates the effect of the Refraction Color parameter to produce glass materials. For the images in this example, the material is with a gray Diffuse color, white Reflection color and Fresnel option on.

 

 


Refraction Color is black (0, 0, 0) (no refraction)

 


Refraction Color is light gray (192, 192, 192)

 


Refraction Color is white (255, 255, 255)

 

 

 


 

Example: The Refraction Glossiness Parameter


This example demonstrates the effect of the Refraction Glossiness parameter. Note how lower Refraction Glossiness values blur the refractions and cause the material to appear as frosted glass.

 

 


Refraction Glossiness is 1.0

 


Refraction Glossiness is 0.9

 


Refraction Glossiness is 0.8

 

 

 


 

Example: The Refraction IOR Parameter


This example demonstrates the effect of the Refraction IOR parameter. Note how light bends more as the IOR deviates from 1.0. The case when the index of refraction (IOR) is 1.0 produces a transparent object. Note, however, that in the case of transparent objects, it might be better to assign an opacity map to the material, rather than use refraction.

 

 


Refraction IOR is 0.8

 


Refraction IOR is 1.0

 


Refraction IOR is 1.3

 


Refraction IOR is 1.8

 

 


 

Example: The Fog Color Parameter


This example demonstrates the effect of the Fog Color parameter. Notice how the thick areas of the object are darker in the two images on the right because of the light absorption of the fog.

 

 


Fog Color is white (255, 255, 255) (no light absorption)

 


Fog Color is gray (128, 128, 128)

 


Fog Color is green (116, 190, 102)

 

 

 


 

Example: The Fog Multiplier Parameter


This example demonstrates the effect of the Fog multiplier parameter. Smaller values cause less light absorption because of the fog; while higher values increase the absorption effect.

 

 


Fog multiplier is 0.3

 


Fog multiplier is 1.0

 


Fog multiplier is 1.5

 

 

 

 


 

Subsurface Scattering


 

 


On – Enables sub-surface scattering for the material.

Translucency Color – Normally the color of the sub-surface scattering effect depends on the Fog color; this parameter allows you to additionally tint the SSS effect.

Subdivs – Controls the quality of the subsurface scattering effect. Lower values will render faster, but the result will be noisier. Higher values take longer but produce smoother results. Note that this parameter is available for changing only when Use local subdivs is enabled in the DMC Sampler Settings.

Fwd/back coeff – Controls the direction of scattering for a ray. 0.0 means a ray can only go forward (away from the surface, inside the object); 0.5 means that a ray has an equal chance of going forward or backward; 1.0 means a ray will be scattered backward (towards the surface, to the outside of the object).

Scatter bounces – Controls how many times the rays will bounce inside the object.

Scatter coefficient – The amount of scattering inside the object. 0.0 means rays will be scattered in all directions; 1.0 means a ray cannot change its direction inside the sub-surface volume.

Thickness – Limits the rays that will be traced below the surface. This is useful if you do not want or don't need to trace the whole sub-surface volume.

Environment fog – When enabled, V-Ray will trace direct lighting into the material.

 

 

Refraction - advanced





Refraction Exit Color on – When enabled and a ray has reached the maximum refraction depth, the ray will be terminated and the Refraction Exit Color value returned. When this is off, the ray will not be refracted but will be continued without changes.

Refraction Exit Color – If a ray has reached it's maximum depth this color will be returned instead of tracing the ray further

Trace Refractions – Enables refractions for the current material.

Max depth – The number of times a ray can be refracted. Scenes with lots of refractive and reflective surfaces may require higher values to look correct.

Affect Channels – Allows the user to specify which channels are going to be affected by the transparency of the material

Color Only – The transparency will affect only the RGB channel of the final render.
Color+alpha – This will cause the material to transmit the alpha of the refracted objects, instead of displaying an opaque alpha.
All channels – All channels and render elements will be affected by the transparency of the material.

Dispersion – Enables the calculation of true light wavelength dispersion.

Dispersion Abbe – Allows the user to increase or decrease the dispersion effect. Lowering it widens the dispersion and vice versa. 

 

Bump and Normal Mapping


 

 

 

Map Type – Determines how the Map parameter is interpreted.

Map – Allows the user to select a texture for the bump or normal map. Leaving this unconnected turns off bump/normal mapping.

Note: When a texture with color corrections is used as a normal map, V-Ray will display a warning for unexpected results .

Bump Mult – A multiplier for the bump map effect.

Bump Shadows – When enabled, produces better looking shadows. Its recommended to keep this parameter disabled.

Bump Delta Scale – This parameter can be decreased to sharpen the bump and Increased to blur it

 

Options


 

 

 

Cutoff Threshold – A threshold below which reflections/refractions will not be traced. V-Ray tries to estimate the contribution of reflections/refractions to the image, and if it is below this threshold, these effects are not computed. Do not set this to 0.0 as it may cause excessively long render times in some cases.

Double-sided – When enabled, V-Ray will flip the normals for back-facing surfaces with this material assigned. Otherwise, the lighting on the "outer" side of the material will be computed always. You can use this to achieve a fake translucent effect for thin objects like paper.

Use Irradiance Map – When enabled, the irradiance map will be used to approximate diffuse indirect illumination for the material. If this is off, brute force GI will be used in which case the quality of the brute force GI is determined by the Subdivs parameter of the Irradiance Map . You can use this for objects in the scene which have small details and are not approximated very well by the Irradiance Map.

Fix dark edges – When enabled, fixes dark edges that some times appear on objects with glossy materials.

 

Hardware Texturing


 

 

 

This is the standard Maya hardware texturing rollout. It enables you to choose which texture connected to the VRayMtl will be displayed in the viewport and with what resolution.

 

https://docs.chaosgroup.com/display/VRAY4MAYA4EDIT/Light+Meter+%7C+VRayLightMeter