The clip_geo shader makes a shape a 'clipping shape'. A clipping shape clips geometry from any shape that intersects with it. For example, a sphere with the clip_geo shader clips geometry from the cubes that intersect with the sphere:
Users can limit the objects that are affected with trace sets, and optionally choose a specific shader for the intersection surfaces if needed.
- clip_geo must be the root shader on the shape.
- Only a single clipping geo object can be used.
- Self-intersecting geometry or intersecting clipping objects can cause artifacts.
- Open objects may cause unwanted clipping (should be as watertight as possible).
- Clipped volumes are not currently supported (expected in a future release).
The intersection surface can be removed by disabling primary_visibility (and cast_shadows) for the intersecting object (sphere).
The color or shader applied to the result of the clipping.
Red shader -> intersection
It is possible to tag objects to be part of one or many trace sets. You can use trace sets to control which objects are clipped.
The muscles use the same trace set name as the clip_geo shader.
The skull & veins objects are omitted because they do not have a trace set name.
If you want only certain objects to be clipped:
- Create a trace set by entering a name in the shader trace_set text box (for example, "objects_to_clip").
- Put the objects in that trace set (by entering the same trace set name for those shapes). Only objects in the trace set will be clipped.
Trace Set name (objects_to_clip) given to Clip Geo shader (left) and clipping object (right)
If you want to avoid clipping some objects:
- Create a trace set by entering a name in the shader Trace Sets text box (for example, "objects_not_to_clip").
- Clear the Inclusive checkbox.
- Put the objects in that trace set (by entering the same trace set name for those shapes).
- All objects not in the trace set will be clipped.
If on, the tracing works in inclusive mode, else in exclusive, as described above.