Ambient Occlusion
What it is

This is a plugin for Maxon Cinema 4D that implements the ambient occlusion algorithm. It is my debut at writing a plugin for Cinema 4D, so it may be buggy, inefficient or contain stupid beginner's mistakes. Still, it is in a usable state and should run with Cinema 4D versions 6 through 8 on both MacOS and Windows.

Installation

Download the plugin here and unzip it. Then copy the respective file for your version of Cinema 4D to the plugin directory of your Cinema 4D installation. Restart Cinema 4D or tell it to reload the plugins. You should now have a new channel shader available in your materials.

Usage

Standart usage for ambient occlusion is as shader for envrionment lighting, usually at a level between 5% and 25%. You can, however, also use it as the only source of lighting at 100%, which will give you results like the image above. For Cinema 4D versions 6 and 7, you will need to check transparency for your channel, otherwise Cinema won't use raytracing on it. The COFFEE routine to tell Cinema that the shader is using raytracing crashes versions 6 and 7 on startup, unfortunately.

Peter Hermans has written a tutorial on how to use my plugin with Cinema 4D

Paramters

Color: The color field allows you to set the color of the ambient light that is being added.

Samples: The number of samples determines the precision and smoothness of the shader.

Max Distance: This is the radius in which other objects will affect the shading of a point.

Tips

Turn on full antialiasing to reduce the noise in the shading. Use the SLA/bhodiNUT Fusion node to use textures or other shaders for ambient occlusion (use the multiply setting).

Version history

1.1: Fixed an issue with backfacing normals.
1.0: Initial release.