The above archive contains a very simple shader for rendering an “rgb” matte pass in Massive. Since Massive does not allow an object’s base color to be changed on a per-pass basis, this shader provides parameters for directly setting the output red, green, and blue channels.
This shader is about as simple as a surface shader can get:
The objects which appear in each output image can be restricted to members of particular groups by providing a “string subset” parameter with a list of groups in a Display call. Only objects in the listed groups will appear in the display image; other objects will be treated as matte objects for that image.
These capabilities can be utilized to produce an arbitrary set of mattes for different scene elements in a single render invocation.
Example: say one wanted to render a matte for agents and a matte for terrain.
Start by creating two small text files, agents.rib, with