Performs clash and clearance analysis on two sets of surface, polysurface, extrusion, or mesh objects. For more information see the Rhino help file for details on the Clash command.
rhinoscriptsyntax.ObjectClash objects0, objects1, clearance)
rhinoscript.object.ObjectClash objects0, objects1, clearance)
objects0 |
Required. List. The first set of object identifiers. |
objects1 |
Required. List. The second set of object identifiers. |
clearance |
Required. Number. The clearance distance. If 0.0, then only clash, or intersection, analysis is performed. If > 0.0, then objects are also analyzed to see if they violate the defined zone of clearance. |
List |
A list that contains tuples of clash and clearance events if successful. The array of event information will contain the following:
|
||||||||
None |
If not successful, or on error. |
import rhinoscriptsyntax as rs
filter = rs.filter.surface + rs.filter.polysurface + rs.filter.mesh + rs.filter.extrusion
objects0 = rs.GetObjects("Select first set for clash detection", filter)
objects1 = rs.GetObjects("Select second set for clash detection", filter)
events = rs.ObjectClash(objects0, objects1, 2.0)
if events:
for event in events:
rs.AddPoints(event[2])