Light Path Expressions Improvements in 3ds Max 2016

Starting with iray in 3ds Max 2015 you can render different bits of information into different buffers using Light Path Expressions (LPEs). LPEs are exposed through iray Render Elements.

LPEs are regular expressions that match some light transport paths that iray generates. Each result buffer can be associated with an LPE so that only paths which match the expression end up contributing to that buffer. The iray renderer also allows you to render several buffers with different LPEs at the same time at almost no additional runtime cost. LPEs can distinguish between different surface properties such as diffuse or glossy, reflection or refraction, types of light sources, and names.

In 3ds Max 2016, LPEs have been extended to allow light-specific and object-specific paths.

Light-specific LPEs allow to render your scene per light source. You can then adjust light intensities in a post process, weighing them together.

Object-specific allow to render your scene per object. You can then perform artistic compositing of an image, for example by subtracting an object’s reflection from the beauty image or by adding glow to the image.

For examples of LPE usage, check out these iray blog posts:
Compositing with Light Path Expressions
Instant Relighting & Nonphysical Effects
Get a grip (2): instant color change

Lights and objects need to be grouped into layers before they can be referenced in LPEs.

Below is an example how to achieve this. You can download the example scene from https://s3.amazonaws.com/arcdownload/irayLPESceneUsingLightsAndObjectsHandles.zip.

Open “Tools/Layer Explorer…” to group objects (e.g. the cosmetic box below is under a layer named “container”):


Grouping geometry in the Layer Explorer

The “container” can then be referenced in an LPE "L.*'container'RE" (reflections of the cosmetic box):


Creating an LPE with object-specific path

containerreflectionsRendering "L.*'container'RE"

In the same way lights can be grouped into layer and referenced in an LPE:


Creating an LPE with light-specific path

right_lightRendering "<L'light_right'>.*E"

Hope you will find this post useful.

mental ray for 3ds Max 2016

Here is an overview of the mental ray and iray features which were integrated in 3ds Max 2016.

NVIDIA Material Definition Language (MDL)

The Material Definition Language (MDL) is an NVIDIA initiative to standardize physically based material designs in a common format, see http://www.nvidia.com/MDL. mental ray for 3ds Max 2016 is capable of rendering pre-packaged MDL materials. We will create a dedicated blog post to explain how to enable MDL in 3ds Max 2016.

mdl_examples_3dsmax Rendering MDL with mental ray

Light Importance Sampling (LIS)

The new Light Importance Sampling mechanism in mental ray allows to sample the whole set of lights as if it were one single light, placing more samples on the lights that contribute more to the part of the scene being rendered. It is an importance-driven mechanism that is controlled by a simple set of parameters. Both area and point lights are importance-sampled, and there is no fundamental change required in material and light shaders. This mechanism is typically useful in scenes with many lights, but can be beneficial also in other simpler cases.


Light Importance Sampling parameters

Ambient Occlusion, GPU accelerated

mental ray offers a new, efficient, GPU accelerated “mr Ambient Occlusion” render element.

aomr Ambient Occlusion Render Element

aoparmsmr Ambient Occlusion parameters

The “Max Distance” controls the maximum distance of occlusion probe rays (Note: Value 0 for “Max Distance” means infinite distance). “Falloff” controls how much the occlusion fades out with distance.

Displacement Settings

The mental ray and the iray renderers now offer the “Parametric” approximation method which can help to troubleshoot scenes where the “Length” method exhibits artifacts, for example scenes with very regular and flat geometry. This method is available from the “Render Setup/Renderer” tab and from the “Object Properties/mental ray” tab.


Object Properties/mental ray tab – Displacement Settings

The parametric approximation method regularly subdivides each triangle of the surface. The “Subdivision Level” specifies how many times each input triangle should be subdivided. A higher “Subdivision Level” results in a higher triangle count. Each input triangle is subdivided into 4(Subdivision Level) triangles. Note: there is an internal limit of 8 million triangles per object.

Section Plane

The iray renderer offers a new helper object “iray Section”. The “iray Section” behaves similarly to the “Grid” helper and is used to cut off the geometry in the rendered image. Section planes can either cut off the geometry completely (so let the light in), or let the viewer take a peek inside, see “Clip Light” parameter. You can define up to 8 section planes.

sectionplaneiray Section Plane Helper

Texture Compression

The iray “Texture Compression” can save around 75% of texture memory on both CPU and GPU. This is enabled by default. See http://blog.irayrender.com/post/54506874080/saving-on-texture-memory for details, the level of compression exposed in 3ds Max 2016 is the “medium”.

texturecompressionTexture Compression parameters

Light Path Expressions Improvements

Light Path Expressions (LPEs) for iray have been extended to allow light-specific and object-specific paths.

Lights and objects need to be grouped into layers before they can be referenced in LPEs.

We will create a dedicated blogpost to explain this mechanism.

Irradiance Render Element

The iray renderer offers a new Render Element “iray: Irradiance”:

irradianceRender Element “iray: Irradiance”

irradiance_parmsIrradiance parameters

It is recommended to turn off tone mapping when computing irradiance. By default the irradiance buffer is converted to a heatmap, displaying the lux (or footcandle) values with false colors:

irradiance_bufferRendering Irradiance with heatmap on

Auxiliary Buffers Render Elements: Alpha, Normal, Depth

The iray renderer also offers auxiliary buffers Render Elements (Alpha, Normal and Depth):

auxiliaryAuxiliary buffers Render Elements

auxiliary_buffersRendering Auxiliary buffers

Here is for the tour of the new mental ray and iray features integrated in 3ds Max 2016.

Hope you will find this useful.

Pascal

mental ray for Maya 2016

In this post, we introduce the newest features of the mental ray for Maya 2016 plugin that is delivered with Autodesk Maya 2016 and can be downloaded here. Stay tuned for more in-depth posts on the features.

Render Settings Redesign

This version comes with a complete new layout of the Render Settings. Our goal is to make the rendering experience with mental ray straight forward and easy. Settings are greatly simplified and grouped together. Five tabs allow to find settings sorted by topic. For advanced users, each tab provides the ‘Advanced Settings’ mode with more detailed controls to fine-tune the rendering.

newRenderSettings

The Scene tab contains a simplified render passes system for standard utility passes

newRenderStandardPasses

as well as MILA Light Path and Matte Pass passes.

newRenderMilaPasses

A more throrough introduction to the new Render Settings will follow shortly.

NVIDIA Material Definition Language

mental ray 3.13 renders materials defined by the NVIDIA Material Definition Language (MDL). MDL is an NVIDIA initiative to standardize physically based material designs in a common format, see http://www.nvidia.com/MDL. Prepackaged MDL materials can be applied in mental ray for Maya 2016. We will provide you with an introduction on how to use MDL in Maya 2016 and with examples for download in this blog soon.

mdl-spheres

Light Importance Sampling By Default

Light Importance Sampling is now enabled by default. It gives a significant speed / quality advantage out of the box especially with modern and complex lighting setups, emissive objects, and very many light sources. In addition, new heuristics have been incorporated that automatically determine which light sources in the scene are physically plausible and would benefit from importance sampling. This way, traditional idealized light sources and simple lighting setups can be detected and handled separately, like they may be excluded from importance sampling to retain an overall benefit even though this feature is generally enabled. Custom light shaders are fully supported and will be included in importance sampling if they adhere to physically plausible emission and distribution rules.

Deep OpenEXR

mental ray 3.13 adds support for generating ‘deep’ data and output to OpenEXR files. The resulting image is saved in the DeepTile form of the OpenEXR 2.0 file format, storing additional information of the pixel colors along the Z axis. It is possible to save deep and simple 2D data into different frame buffers during the same rendering.

UV Tiles Optimized

Rendering UV-tiled textures is faster and more memory efficient in this version because it is based on a native mental ray shader. It auto-creates and loads the tile textures into mental ray on demand, making sure that only those tiles that are actually accessed get loaded into memory. The shader is part of a new package called coreutil, which collects essential mental ray utilities and helper functions.

Create Lights menu 

There is a new section in the Create|Lights menu for mental ray lights showing modern mental ray lights in a prominent and easily accessible place.

createLightMenu

Object Lights

Using custom geometry to light your scene is now possible with mental ray for Maya 2016. You can assign the new ‘Object Light’ material to your geometry or, with the geometry selected, you can choose ‘Object Light’ from the new mental ray section in the Create|Lights menu. This will turn your geometry into a light.

 light_bulb_cropped

                           Light bulb model courtesy of David Hackett.

Rendering Bifrost with mental ray

Bifröst is a procedural framework that can create simulated effects ranging from liquid to foam, bubbles, spray and mist. These effects can be rendered using the bifrost geometry shader delivered with mental ray for Maya 2016.

Autodesk published videos on bifrost and showing mental ray rendering at the end of each:

Maya 2016: Adaptive Aero Solver in Bifrost
Maya 2016: Guided Simulations in Bifrost
Maya 2016: Adaptive Foam in Bifrost

XGen hair shading and displacement

Rendering XGen with mental ray has been improved and enhanced with new features.

The default XGen hair shader for mental ray is now xgen_hair_physical. It is based on the mental ray human hair shader mib_illum_hair_x which has been improved with mental ray 3.13. It now adds contributions from indirect lighting to the shading. New parameters have been added to tune the tube shading look and to control the internal color noise effect.

Displacing sphere and dart primitives is now possible allowing for a much wider use-case for these primitives.

xgen-spheres-with-displacement

Texture Filtering based on Ray-Differentials

For advanced ‘elliptical’ texture filtering in Maya’s file node, we are now using ray differentials provided by mental ray core. This introduces more accurate and artifact-free texture filtering even across ray traced reflections and refractions.
To enable it, select a file node, choose ‘Mipmap’ as filtertype, go to the mental ray section and enable ‘Elliptical filtering’. You can choose between ‘Bilinear’ or ‘Bicubic’ filter mode.