misss_fast_shader

 
 
 

Category: mental ray > Materials

Shader Family: Surface Material

Output: Color

This shader is the workhorse shader that does the actual scattering. It is highly modular and works with several input shaders that provide the actual contribution for the various layers through the bump, diffuse_illum, and specular_illum input ports. This shader can even be cascaded into itself (again using the diffuse_illum port) for multi-layer scattering (this is exactly how the Fast Skin Subsurface Scattering phenomenon works). The misss_fast_shader layers the results from the input shaders with the scattered light from the lightmap and then presents the final shaded result.

This shader can be connected into multiple copies of itself via its diffuse_illum port for multi-layer scattering, but the final destination is usually to have its result output port connected to the Material node's Surface input port.

Name

The name of the shader node displayed in the render tree. Enter any name you like, or leave the default.

lightmap

depthmap

Specifies a writable color texture and depthmap.

You can Edit the image clip, or get a New image clip from file or from source. For more information about working with images, see Managing Image Sources & Clips [Data Management].

bump

Pick the shader that perturbs the normals. While one could use a shader list and something like mib_passthrough_bump_map before this shader, for large scattering radii it is preferred that the shader is aware of the normal vector before bump mapping. When a bump mapping shader is assigned to this parameter instead, misss_fast_shader will know the normal both before and after bump mapping.

diffuse_illum

Passes any normal illumination shader (returning a color) as the diffuse illumination, generally mib_illum_lambert is be used. If nothing is passed, it automatically defaults to Lambert.

diffuse_color

Defines the color of the diffuse illumination component. This is normally driven by the object's main surface texture.

specular_illum

Passes any normal illumination shader (returning a color) for the specular and reflective components. If nothing is passed, no specular shading happens. This is layered on top of any diffuse contributions.

diffuse_weight

Controls the weight of the diffuse illumination component when it is blended with the other components (ambient, scattering, etc.).

front_sss_color

Controls the color for the front surface scattering. The front surface is the side of the object facing the camera, and so front surface scattering is most visible when that side is well lit.

front_sss_weight

Controls the weight of the front scattering surface when it is blended with the other lighting components (back scattering, diffuse, etc.).

front_sss_radius

Controls the distance that light scatters along the front surface. This value is measured in scene units, but is divided by the Scale value on the Advanced Settings tab.

back_sss_color

Controls the color for the back surface scattering (the light going through the object). The Back surface is the side facing away from the camera. Back scattering is most visible when the object is backlit to some extent, or when light passes directly through the object.

back_sss_weight

Controls the weight of the back scattering when it is blended with the other lighting components (front scattering, diffuse, etc.).

back_sss_radius

Controls the distance that light scatters along the back surface. This value is measured in scene units, but is divided by the scale value on the Advanced Settings tab.

Normally, the back scattering radius should be set to the same value as the back_sss_depth parameter.

back_sss_depth

Controls the back scatter depth. The higher the value, the more deeply light is scattered within the object. In effect, raising the depth makes the object appear more translucent when backlit.

Generally speaking, higher depth values require an increased number of lightmap samples in order to remove speckling in the rendered image.

Normally, the back scattering depth should be set to the same value as the back_sss_radius parameter.

scale

A simple utility function that allows a linear division of all distances. Since scattering is distance dependent, loading a material designed for a model made in inches will not work on a model where the unit is meters, and vice versa. Use this option as the conversion factor for scale.

screen_composit

When enabled, screen compositing is used. When adding together the contribution of many layers of light, it is very easy to quickly blow out and overexpose into white, but the human eye is inherently nonlinear and perceives intensities in a different way. This option allows you to use what is known in many compositing applications as a screen transfer mode between the layers, which yields a softer, more pleasing result.

When disabled, normal addition is used. If rendering in a high dynamic range, and a proper tone-operator is applied in the final output stage already compressing the final luminance, it is best to disable this option. If not, enable it for a more pleasing result.

output_sss_only

Use for debugging and testing or for preparing for external compositing. When enabled, only the scattered contribution is shown.

falloff

Defines the falloff profile for light scattered along the radius. Higher values cause a sharper falloff. Lower values cause a smoother falloff but cause the scatter distance to appear shorter, though you can increase the Radius value to compensate.

For high values (1.0 to 10.0), almost all samples within the scatter radius are weighted equally. For low values (0.1 to 1.0), the samples near the edge of the scatter radius are weighted as less.

samples

Specifies the number of lightmap samples considered by each rendered ray. Generally, this should be set to a power of two (16, 32, 64, 128, etc.).

Subtle scattering effects typically require few samples. However, as you begin to increase the front and back scattering radii, or the back scattering depth, you will need to increase the number of samples to avoid speckling in the rendered image.