Sampling Quality Rollout (mental ray Renderer)

The controls on this rollout affect how the mental ray renderer performs sampling for antialiasing rendered images.

Procedures

To view the sampling pattern:

Interface

Sampling Mode drop-down list
Lets you choose the kind of sampling to perform.
  • Unified / Raytraced (Recommended) (The default.) Raytraces the scene using the same sampling method for both antialiasing and calculating motion blur. This results in far quicker rendering than the Classic method.
  • Classic / Raytraced Uses Minimum/Maximum sampling multipliers, as in releases of 3ds Max prior to 3ds Max 2014.
  • Rasterizer / Scanline Similar to Classic / Raytraced mode, but raytracing is disabled.

    Rasterizer / Scanline mode uses sampling values rather than Minimum/Maximum multipliers. The Contrast/Noise controls are not available.

Samples per Pixel group

The controls that appear in this group depend on the mode that is active: Unified, Classic, or Rasterizer.

Unified / Raytraced (Recommended) mode

Quality
Sets the quality of rendering. Lower values render faster but give grainier images. Higher values give smoother images but take longer to render. Range: 0.1 to 20.0. Default=0.25.

Quality essentially sets the "noise level" at which the renderer stops sampling. Higher quality implies less noise. The Spatial Contrast threshold sets the lowest level of acceptable noise.

Quality=0.25 (the default)

Quality=0.1

Quality=20.0

Minimum
Sets the minimum sample rate. Range: 0.1 to 64.0. Default=1.0
Maximum
Sets the maximum sample rate. Range: 1 to 100000 (one hundred thousand). Default=128.0.
Note: Unlike Minimum/Maximum for Classic mode, Minimum/Maximum for Unified mode can span a wide range and give good results. However, it is easier just to adjust the Quality setting.

Classic / Raytraced mode

Set the minimum and maximum sample rates for antialiasing the rendered output.

Note: Presets for several sample rate combinations are available on the Rendered Frame Window as the Image Precision (Antialiasing) slider.
Minimum
Sets the minimum sample rate. The value represents the number of samples per pixel. A value greater than or equal to 1 indicates that one or more samples are computed per pixel. A fractional value indicates that one sample is computed for every N pixels (for example, 1/4 computes a minimum of one sample for every four pixels). Default=1/4.
Maximum
Sets the maximum sample rate. If neighboring samples find a difference in contrast that exceeds the contrast limit, the area containing the contrast is subdivided to the depth specified by Maximum. Default=4.

The values of the Minimum and Maximum lists are "locked" together so that the value of Minimum can't exceed the value of Maximum.

Note: For Classic mode, the range between Minimum and Maximum should not be great. For example, if Minimum=1/4, Maximum should not exceed 16, or artifacts can occur.

To use low sampling for previews, leave the Minimum and Maximum values at their default settings of 1/4 and 4, or reduce them to 1/16 and 1/4. To use high sampling for final renderings, increase the Minimum and Maximum values to 4 and 16, respectively, or to higher values.

Tip: Do not assign Minimum and Maximum the same value.

Rasterizer / Scanline mode

Rasterizer / Scanline mode dices objects into micro-polygons. It shades each micro-polygon once and gives it a color from the result of this shading. Then these micro-diced polygons are moved across time, and sampled by the Visibility samples. This allows effects like motion blur to be resolved with many samples (smooth motion blur), without having to do the computationally expensive shading process for each sample. It is as if the renderer renders a still frame at a fixed number of samples per pixel (the Shading samples), and then reuses that image and smears it over time, with the help of the Visibility samples.

Shading
Controls the approximate number of shading calls per pixel. Greater values result in more accurate renderings, at a cost of render time. Range=0.1 to 10000 (ten thousand). Default=2.0.
Visibility
Controls the number of samples per pixel used by Rasterizer mode. More samples result in greater smoothness, at a cost of render time. Range=1 to 225. Default=16.
Note: The mental ray renderer provides a Time Samples setting specifically for motion blur in Rasterizer / Scanline mode. When Rasterizer mode is active, the Camera Effects rollout Time Samples label changes to Time Samples (Fast Rasterizer) to indicate that this version of Time Samples is now in effect.

Filter group

Type drop-down list
Determines how multiple samples are combined into a single pixel value. Can be set to Box, Gauss, Triangle, Mitchell, or Lanczos. Default=Box.
Tip: For most scenes the Mitchell filter gives the best results.
  • Box filter: Sums all samples in the filter area with equal weight. This is the quickest sampling method.
  • Gauss filter: Weights the samples using a Gauss (bell) curve centered on the pixel.
  • Triangle filter: Weights the samples using a pyramid centered on the pixel.
  • Mitchell filter: Weights the samples using a curve (steeper than Gauss) centered on the pixel.
  • Lanczos filter: Weights the samples using a curve (steeper than Gauss) centered on the pixel, diminishing the effect of samples at the edge of the filter area.
Width and Height
Specify the size of the filtered area. Increasing the value of Width and Height can soften the image, however it will increase rendering time.

Default=Depends on the Type you choose:

  • Box filter: Width=1.0, Height=1.0
  • Gauss filter: Width=2.0, Height=2.0
  • Triangle filter: Width=2.0, Height=2.0
  • Mitchell filter: Width=4.0, Height=4.0
  • Lanczos filter: Width=4.0, Height=4.0

Contrast / Noise Threshold group

Set the contrast value used as thresholds to control sampling. Spatial contrast applies to each still image.

These controls are disabled for Rasterizer / Scanline mode.

If neighboring samples in a frame differ by more than this color, the mental ray renderer does recursive supersampling (that is, more than one sample per pixel), up to the depth specified by the Maximum samples per pixel value. Increasing the Spatial Contrast values decreases the amount of sampling done, and can speed the rendering of a scene at the cost of image quality.

  • R, G, B Specify the threshold values for the red, green, and blue components of samples. These values are normalized, and range from 0.0 to 1.0, where 0.0 indicates the color component is fully unsaturated (black, or 0 in eight-bit encoding) and 1.0 indicates the color component is fully saturated (white, or 255 in eight-bit encoding). Default=(0.01, 0.01, 0.01).
  • A Specifies the threshold value for the alpha component of samples. This value is normalized, and ranges from 0.0 (fully transparent, or 0 in eight-bit encoding) to 1.0 (fully opaque, or 255 in eight-bit encoding). Default=0.01.
  • [color swatch] Click to display a Color Selector to let you specify the R, G, and B threshold values interactively.

Options group

Lock Samples
When on, the mental ray renderer uses the same sampling pattern for every frame of an animation. When off, the mental ray renderer introduces a quasi-random (Monte Carlo) variation in the sample pattern from frame to frame. Default=off.

Varying the sample pattern reduces rendering artifacts in animations.

Jitter
Introduces a variation into sample locations; see Sampling. Turning on Jitter can help reduce aliasing. Default=on.
Bucket Width
Determines the size of each bucket in pixels. Range=4 to 512 pixels. Default=32 pixels.

To render the scene, the mental ray renderer subdivides the image into rectangular sections, or “buckets.” Using a smaller bucket size causes more image updates to be generated during rendering. Updating the image consumes a small number of CPU cycles. In most cases, adjusting this value has little or no effect on rendering time, but when rendering very large images, you can achieve faster results by setting Bucket Width to about 1/10th of the largest dimension in pixels. For example, when rendering a 4000 x 3000 image, set Bucket Width to 400.

Tip: Each bucket is assigned to one CPU, so in multiprocessor systems, be sure to set Bucket Width so that all CPUs are used to render the image. For example, if you have eight CPUs and make your image using four buckets, four CPUs will go unused.
Bucket Order
Lets you specify the method by which mental ray chooses the next bucket. If you are using placeholders or distributed rendering, use the default Hilbert order. Otherwise, choose a method based on how you prefer to see the image appear as it renders in the Rendered Frame Window.
  • Hilbert (best) (The default.) The next bucket chosen is the one that will trigger the fewest data transfers.
    Tip: Always use Hilbert order when you use placeholders (see the Translator Options rollout) or distributed rendering (see the Distributed Bucket Rendering rollout).
  • Spiral The buckets begin at the center of the image, and spiral outward.
  • Left to right Buckets are rendered in columns, from bottom to top, left to right.
  • Right to left Buckets are rendered in columns, from bottom to top, right to left.
  • Top-down Buckets are rendered in rows, from right to left, top to bottom.
  • Bottom-up Buckets are rendered in rows, from right to left, bottom to top.
Frame Buffer Type
Lets you choose the bit depth of the output frame buffer:
  • Integer (16 bits per channel) Outputs 16 bits per channel of color information. In 3ds Max, this is the default output format.
  • Floating-Point (32 bits per channel) Outputs 32 bits per channel of color information. This method supports high-dynamic-range imagery (HDRI).
    Important: Floating-point, 32-bit output is required for lighting analysis.

    When you render an image with floating-point, 32-bit output, you might see jagged edges in bright areas such as self-illuminated objects or reflections of light sources. The reason is that in floating-point rendering, the brightness of a pixel can be greater than 1 (“whiter than white,” so to speak).

    Left: In a 16-bit rendering, bright highlights are muted.

    Right: In a 32-bit rendering, bright highlights (on the lamp chains and the mirror), are strong and jagged.

    For example, suppose a pixel is sampled four times, and an object occludes the pixel one of those times. In a 16-bit rendering, this results in a 25 percent grayscale value for the pixel. The same thing happens in a 32-bit rendering, unless the object is bright. In that case, the pixel might be 20 times brighter than its surroundings, so the result does not blend into its surroundings, and the rendered highlight appears to be jagged or “aliased.” While this effect is apparent in the 3ds Max Rendered Frame Window, it is only apparent: if you use the image in a compositing program that handles HDRI images, for example, or open it and adjust its levels in an image-processing program such as Photoshop, the image appearance will be correct.

Light Importance Sampling group

Enable
Light Importance Sampling (LIS) increases the number of samples taken for lights that are brighter relative to the current point being shaded. This can reduce the amount of noise (graininess) and improve the accuracy of the rendering. By default, sampling is cross-balanced among all light sources. Default=on.
Quality
Multiplies the number of samples taken at each point. At the default value of 1.0, the renderer takes the same number of samples as when LIS is disabled, but light sources are cross-balanced. Range: 0.0 to 20.0. Default=1.0.