mental ray supports an extra data type "coverage" that creates a separate frame buffer containing the fraction of each pixel covered by the most samples in that pixel. Oversampling often takes several samples (primary rays) in a pixel for anti-aliasing; the samples are averaged. At points where one object overlaps another, one object may account for more of the pixel than the other, which might just touch a corner of the pixel. In such a case, the coverage frame buffer specifies exactly how much of the pixel the "more important" object covers. This is a number in the range 0 (the pixel is empty) to 1 (an object covers the pixel completely). If the coverage buffer is written to a file, a scalar format such as st should be chosen. mental ray can also convert to RGB/A formats such as TIFF.
Since mental ray is a point-sampling renderer, the precision is bounded by the number of samples taken, which depends on the oversampling settings (samples option). Two objects are considered different if their object tags differ. Object tags are defined with tag statements in the object definition in the scene file.
If coverage calculation is enabled by adding the appropriate output statement, the depth, normal, motion, and tag frame buffers, if also enabled and marked with a "-" (which is the default), are guaranteed to come from the object that had the most coverage.
Copyright © 1986-2008 by mental images GmbH