5. MeshBoolean plugin
MeshBoolean is a standard plugin of cloudComPy.
The availability of the plugin can be tested with the cloudComPy.isPluginMeshBoolean()
function:
isMeshBoolean_available = cc.isPluginMeshBoolean()
MeshBoolean is a submodule of cloudCompy:
import cloudComPy as cc
# ...
if cc.isPluginMeshBoolean():
import cloudComPy.MeshBoolean
cc.MeshBoolean.computeMeshBoolean(...)
- class cloudComPy.MeshBoolean.CSG_OPERATION
Members:
UNION
INTERSECT
DIFF
SYM_DIFF
- DIFF = <CSG_OPERATION.DIFF: 2>
- INTERSECT = <CSG_OPERATION.INTERSECT: 1>
- SYM_DIFF = <CSG_OPERATION.SYM_DIFF: 3>
- UNION = <CSG_OPERATION.UNION: 0>
- __init__(self: _MeshBoolean.CSG_OPERATION, value: int) None
- property name
- property value
- cloudComPy.MeshBoolean.computeMeshBoolean(arg0: _cloudComPy.ccMesh, arg1: _cloudComPy.ccMesh, arg2: _MeshBoolean.CSG_OPERATION) _cloudComPy.ccMesh
Compute boolean operation on two meshes. (plugin MeshBoolean)
The boolean operation are UNION, INTERSECT, DIFF, SYM_DIFF. Original meshes are not modified, a new mesh is built.
- Parameters:
MeshA (ccMesh) – first mesh.
MeshB (ccMesh) – second mesh.
operation (CSG_OPERATION) – from cc.MeshBoolean.CSG_OPERATION (UNION, INTERSECT, DIFF, SYM_DIFF)
- Returns:
new mesh or None
- Return type:
- cloudComPy.MeshBoolean.initTrace_MeshBoolean() None
Debug trace must be initialized for each Python module.
Done in module init, following the value of environment variable _CCTRACE_ (“ON” if debug traces wanted)