You are here: Shading and Lighting > Shader Tree Item Layers > Shader

Shader

By default, each new scene has a single base Shader Item. This item reads the information from the entire Shader Tree and computes the effects of the illumination on all the surfaces in the scene. This makes the base Shader Item the most important layer in the tree. Shaders also control the Shading Rate, which is the rate that Modo uses to evaluate pixels before sending them to the render item. This breaks up a single pixel for texture computing and anti-aliasing.

Additionally, shaders control visibility of surfaces in a scene and what rays are seen by specific surfaces. For example, you may want to make only the shadow of an object visible. In most cases, you won't change the settings in the shader; however, where specific surfaces need additional control (such as limiting Monte Carlo shading to a single surface, hiding a group of lights from illuminating a single surface, or even hiding an entire object from a camera), you may need to add an additional shader with appropriate settings applied.

Assigning Item-Specific Shaders

In situations where you need additional shading control for a specific surface or item (such as making a single item invisible to a reflection), you can add another shader to the scene. Because of the layered aspect of the Shader Tree, any additional shaders need to be placed above the base shader within its own material group mask. (Otherwise, the base shader settings override it.) A simplified approach is to apply an item-specific shader. These shaders work outside of the Shader Tree, itself, to act as individual item-based overrides of the Shader Tree settings. You add and select item shaders within the Items list. After right-clicking the target layer, choose Create Item Shader and assign the shader to the item. Clicking the + sign preceding the layer's name displays the shader below the item. You can then select the shader and modify its attributes in the Properties panel. Watch the video to learn the process.

There are several options to control visibility of the attributes of the elements feeding the shader. For instance, with the Visibility controls, you could create a bright luminous polygon that is visible to indirect illumination but invisible to reflections, ray-traced shadows, reflection, and the camera. This creates a virtual light element that you can place anywhere in the scene for illumination purposes without worrying about it affecting other visual aspects of the project.

When applying the item shader for a specific task, you can disable the Control (or Compute) options except for the targeted adjustment. For example, to control the visibility of an item, you could disable Compute Shading, Control Quality, Control Lighting, and Control Fog. Then disable Visible to Camera. Now the target item is invisible to the camera, but it still casts a shadow and shows up in reflections. Shaders applied to items simplify certain tasks like these and keep the Shader Tree free of additional layers.

NOTE:  For information about adding and working with Shader Tree item layers, see the Shader Tree topic.

Shader Item Panel

Option

Description

Layer

Enable

Toggles the effect of the layer on and off to duplicate the functionality of toggling visibility in the Shader Tree. When disabled, the layer has no effect on the shading of the scene. However, Modo saves disabled layers with the scene, and they are persistent across Modo sessions.

Invert

Inverts the colors (RGB values) for the layer to produce a photonegative effect.

Blend Mode

Affects the blending between different layers of the same effect type. With this, you can stack several layers for different effects.

For more about blending, see the Layer Blend Modes topic.

Opacity

Changes the transparency of the current layer. Reducing this value increasingly reveals lower layers in the Shader Tree, if present, or dims the effect of the layer on the surface.

Shader

Compute Shading

When enabled, computes the shading attributes for the scene (such as Diffuse or Specular). When applied as an item shader (where the shader, itself, is applied in the Items list rather than the Shader Tree), Modo computes the shader outside the Shader Tree and overrides the Shader Tree settings. When disabled, Modo reverts to the Shader Tree evaluations.

Control Quality

When enabled, activates the Shading Rate, Multiplier, Saturation, and Indirect Illum Type settings. When applied as an item shader (where the shader is applied in the Items list rather than the Shader Tree), Modo computes the shader outside the Shader Tree and overrides the Shader Tree settings. When disabled, Modo reverts to the quality setting evaluations of the Shader Tree.

Shading Rate

Determines how finely to shade each pixel when the material feeds the selected shader item during initial shading. (The Shading Rate is also known as the coarse shading rate.) The default value of 1 indicates that Modo evaluates the pixel once before being evaluated for further refinement. (See the Refinement Threshold option in the Render Item: Settings topic.) Decreasing the Shading Rate results in a more finely evaluated pixel, which generally yields longer render times. For example, if you change the value to .5, Modo cuts the pixel in half horizontally and vertically and evaluates each subpixel. In this case, you reduced the rate by half but increased the number of evaluation 4 times. Small changes to the Shading Rate can produce significant changes in performance.

Generally, you can leave the Shading Rate at 1 and achieve refinement with the Antialiasing level or the Refinement Shading settings. However, when you see aliasing in reflections (or refractions) or on procedural textures, you could rectify the aliasing with the Shading Rate setting. Because doing this affects all the evaluated pixels, it is a brute force solution; and, therefore, you should manually restrict the pixels that are affected by the Shading Rate. Create shaders for specific problem areas with masks and only decrease the Shading Rates where absolutely necessary.

Direct Illum Multiplier

Affects the direct light intensity at the shader item level. Direct illumination is light coming from traditional 3D light sources (such as directional, spot, area, distant, cylinder, dome, and point lights). By default the value is set to 100%. For example, if your project has three lights of varying intensity (such as 100%, 70%, and 30%), setting the Direct Illum Multiplier to 50% decreases these values to 50%, 35%, and 15% respectively. You can use this value to adjust overall light effects as well as balancing direct and indirect light contributions.

Indirect Illum Multiplier

Provides a global method for controlling the indirect light contribution for the final render. Indirect light comes from global illumination sources (such as luminous geometry, image-based lighting through environments, and simple bounced light from diffuse surfaces). Adjust this option when indirect light sources are too subtle (or too pronounced) or to balance direct and indirect light contributions.

Incoming Indirect Saturation/Outgoing Indirect Saturation

Controls the strength of the colors (or saturation amount) generated by indirect illumination independent of the illumination itself. One of the many benefits of indirect illumination is the color bleeding between surfaces. The rays take into account not only the color of the lights and the environment, but the surface's color as well. You can adjust both incoming and outgoing rays. Increasing the value above 100% makes the colors stronger and more saturated, and values below 100% decrease the effect.

Indirect illum Type

Controls the type of global illumination per surface by using a shader with an associated mask. Generally, you control indirect illumination globally through the Render Properties panel on the Global Illumination tab. With the Indirect Illum Type setting, you have the option of using Irradiance Caching for an exterior scene, but using the Monte Carlo method on complex surfaces (such as the trees and bushes).

You can create a selection set for just the trees and bushes (by choosing Select > Assign Selection Set) and in the Shader Tree, add an additional Material Group item above the base shader. In the group Properties panel, set Tag Type to Selection Set and select the named set under Polygon Tag. In this group, add its own shader and set the Indirect Illum Type to Monte Carlo. Now, most of the scene uses Irradiance Caching and only the trees and bushes use the Monte Carlo method. The Indirect Illum Type draws its values from the Render Properties panel on the Global Illumination tab. For the Monte Carlo method, Modo uses the number of rays indicated by the Indirect Rays value of the Properties tab of the Render Item.

Visibility

Control Visibility

When enabled, computes the visibility attributes for the item or scene. When applied as an item shader (applied in the Items list rather than the Shader Tree), Modo computes the shader outside of the Shader Tree and overrides the Shader Tree settings. When disabled, Modo reverts to the Shader Tree evaluations for visibility.

Cast Shadows

When enabled, creates shadows for all elements controlled by the shader. When disabled, causes all elements controlled by the shader to be ignored by shadow rays. Light simply passes through the elements without creating shadows. Disabling this control does not disable shadow effects from indirect illumination because this control only affects direct light sources.

Receive Shadows

When enabled, receives ray-traced shadows from other geometry. When disabled, causes the elements to stop receiving ray-traced shadows from other geometry in the project.

Visible to Camera

When enabled, makes elements controlled by the shader visible to the camera. When disabled, hides any item or element controlled by the shader from the camera. These elements may still appear in shadows, reflections, and refractions even when hidden.

Visible to Indirect Rays

When enabled, uses elements controlled by the shader in any indirect light calculations. Indirect light is any light calculated during global illumination (such as luminous geometry, images used as light sources and other light bounced from geometry). When disabled, removes the elements controlled by the shader from indirect light calculations.

Visible to Reflection Rays

When enabled, reflects elements controlled by the shader in mirror surfaces. When disabled, removes the elements controlled by the shader from reflecting in mirror surfaces.

Visible to Refraction Rays

When enabled, makes elements controlled by the shader visible when looking at them through refractive surfaces. When disabled, causes the elements controlled by the shader to be invisible when looking at them through refractive surfaces.

Visible to Occlusion Rays

When enabled, uses elements controlled by the shader in any occlusion ray calculations. When disabled, causes the elements controlled by the shader to be invisible to occlusion ray calculations.

Alpha Type

Specifies how surfaces contribute to a rendered Alpha channel.

Opacity - Specifies the Alpha value based on the transparency of each individual surface.

Constant - Uses a specified, fixed Alpha Value for all associated surfaces.

Shadow Catcher - Makes all associated surface attributes invisible and exclusively renders shadows cast by direct and indirect illumination. This is a slightly different function from the other options. With this you can compose rendered images with background photos right in Modo. You can set a ground plane to catch the shadows cast by another object without contributing any shadows of its own. When you specify a photo as a background, Modo renders all the objects and shadows together in one pass. View the video to learn the process:

Alpha Value

Overrides surface opacity settings and determines to what degree surfaces contribute to a rendered Alpha channel when Constant is the Alpha Type.

Light Linking

Control Light Linking

When enabled, computes the visibility of light groups for a given item or surface. When applied as an item shader (applied in the Items list rather than the Shader Tree), Modo computes the shader outside of the Shader Tree and overrides the Shader Tree settings. When disabled, Modo reverts to the Shader Tree evaluations for light linking.

Light Group

Controls, on a shader level, what lights in a scene affect which surfaces. You can specify which group of lights to control. You make light groups in the Groups Viewport. To create a base group, click new group, rename it if you wish, and add items by selecting the lights in the 3D Viewport. (Press Shift to select multiple items.) Now, right-click the group's title and choose Add Items. You can also drag items directly from the 3D Viewport onto any Group Item to add them.

Mode

Specifies how the lights affect surfaces. If set to Include, the lights affect the shaded surfaces. If set to Exclude, the lights do not affect shaded surfaces.

Fog

Control Fog

When enabled, produces a simulated (non-volumetric) fog effect by applying a user-defined color to relevant materials with increased intensity as the geometry is further from the camera. You can use this to fade objects into a background by increasing the apparent depth (and scale) of a scene. You can also specify fog in the Environment Material item with similar options. The Environment Fog option differs in that it always uses the environment color, but with the shader fog, you can specify any color.

Fog Type

Specifies the fog type. Click to view examples of various Fog Type settings. (Click an example to see a larger image.)

None - Disables fog from rendering.

Linear - Renders fog in the scene based on the Fog Start Distance and the Fog End Distance. (There is no fog up to the starting distance, but then surfaces attenuate toward a solid color and maximum fog density at the end distance.)

Exponential - Renders fog starting at the camera's position and increases in strength the further the surface is from the camera. Based on exponential values, the strength increases non-linearly and is directly influenced by the Fog Density setting. (For very large scenes, use a very small Fog Density value.)

Underwater - Renders fog starting at the camera's position and increases in strength the further the surface is from the camera — except with this type the fog absorbs the environment's color to produce an environment-colored cast. This type also reduces color saturation with distance. For this type, the example shows a late afternoon environment, so the reds of the setting sun influence the fog's color. For a true underwater look, define a blue or teal color (or set the environment to a 2- or 4-color gradient with blues or greens) and enable Use Environment Color.

Layered - Produces a ground fog-like effect where the fog density increases with both depth and height.

Use Environment Color

Gives the illusion that the mesh is fading into the background because it colors the fog based on the environment material or textures. This option is only available when you specify Underwater as the Fog Type.

Fog Color

Specifies the RGB color to apply to materials receiving fog.

Fog Start Distance/Fog End Distance

Specifies the starting and ending distances for the fog effect when the Fog Type is set to Linear.

Fog Density

Determines how thick the fog is just in front of the camera. The default value of 10% indicates that geometry just in front of the camera has a 10% blend of the fog color. The fog's density increases as it recedes from the camera.

None

No Fog

 

Linear

Linear Fog

 

Exponential

Exponential Fog

 

Underwater

Underwater Fog

 

Layered

Layered Fog