| Previous Topic (Ambient PME Feature) | Up (Rendering In Krakatoa) | Next Topic (Krakatoa Shadows Generator) |
Matte Objects Rasterizer
Available in Krakatoa v1.5.0 and higher
Overview
- Matte objects in Krakatoa are intended as stand-ins for geometry that will be rendered in other renderers like 3ds Max Default Scanline renderer, mental ray, Brazil r/s, final render or VRay to name a few.
- Matte objects can occlude light thus casting shadows onto particles as well as occlude particles as seen from the camera point of view.
- In addition, opacity mapped Matte Objects are now supported as well as the generation of two output image layers - one with foreground particles and one with background particles that could be partially occluded by semi-transparent portions of the Matte Objects.
- In earlier versions of Krakatoa, Matte Objects were implemented using a raytracer accelerated by a kd-tree structure.
- It provided two modes
- Depth Maps where the geometry from the kd-tree would be converted into a Depth Map by shooting rays through every pixel of the attenuation map or final image, then every particle would be compared to the Depth value stored in the map to determine if it is in front or behind a Matte Object
- Brute-Force Raytracing where each particle would be checked against the Matte Objects by shooting a ray into the kd-tree.
- It provided two modes
- Both modes have been removed and replaced with a Depth Map Rasterizer (a form of Scanline algorithm) which is several orders of magnitude faster in generating a Depth Map which is then used to check the particles against.
- For example, rendering 50 million particles in Particle Mode, pre-loaded in PCache and occluded by the 1 million faces of the Stanford Buddha model shows the following performance numbers:
- Pure Render time without Matte Object: 42.375 seconds.
- Generating Matte Objects Depth Map: 0.610 seconds.
- Pure Render time with Matte Objects: 54.625 seconds (12.25 seconds overhead)
- Similarly, rendering 10 million particles in Voxel mode illuminated by one Spot Light and occluded by the same mesh, the performance numbers were:
- Render time without Matte Objects: 22.578 seconds.
- Render time with Matte Objects: 21.641 seconds (0.937 seconds faster!)
- This is caused by the fact that the slowest part of voxel rendering is the actual filling of the voxels, so the more the Matte Objects occlude voxels, the faster the rendering!
- For example, rendering 50 million particles in Particle Mode, pre-loaded in PCache and occluded by the 1 million faces of the Stanford Buddha model shows the following performance numbers:
Opacity Mapped Matte Objects
A new feature of Krakatoa v1.5.0 is the support for opacity-mapped Matte Objects. Although Krakatoa supports semi-transparent objects as matte objects, compositing such renders with other render elements is not always possible (it would require more than two output layers if there are overlapping semi-transparent objects).
The following examples show Particle and Voxel rendering without matte objects, with a plane without opacity mapping and the same plane with an opacity mapped bitmap texture of a leaf.
Rendering times for the Particle mode were: 3.625 | 3.734 seconds
Rendering times for the Voxel mode were: 7.875 | 8.469 seconds.