Skip to main content
Version: 2026R2

CADGeometry

class compolyx.CADGeometry(graph, obj, visible_sub_shapes=None, parent=None)

Attributes

NameDescription
CADGeometry.activeActive status of object
CADGeometry.cad_compoundsDictionary with all compounds in the CAD geometry
CADGeometry.cad_facesDictionary with all face shapes
CADGeometry.cad_solidsDictionary with all solid shapes
CADGeometry.cad_surfacesDictionary with all shell shapes
CADGeometry.changedStatus boolean
CADGeometry.display_dataCAD geometry mesh surface plot
CADGeometry.element_to_face_map
CADGeometry.enabledWhether this object is currently enabled or not
CADGeometry.ext_idExternal ID of the CAD Geometry object
CADGeometry.idID of object
CADGeometry.is_dict_itemSpecifies whether the object is an item of a dict
CADGeometry.is_list_itemSpecifies whether the object is an item of a list
CADGeometry.link_pathRoot path of the current node in the tree for links to this object
CADGeometry.lockedCAD geometry is generated from an imported geometry and cannot be changed
CADGeometry.nameName of object
CADGeometry.normals_display_dataCAD geometry normals visualization
CADGeometry.offsetOffset value used to analyze the surface's coverage regarding the mesh
CADGeometry.parentParent object in tree
CADGeometry.pathThe file path where the CAD geometry is loaded from
CADGeometry.precisionPrecision of geometrical operations (intersection points, thickness sampling, etc.)
CADGeometry.root_pathRoot path of the current node in the tree
CADGeometry.root_shapesDictonary with all free shapes of the CAD geometry
CADGeometry.scale_factorGeometry is scaled with this factor
CADGeometry.shape_typeTopological type of the shape
CADGeometry.show_normalsVisibility of face normals
CADGeometry.statusStatus of the object
CADGeometry.status_changedBoolean flag which is set to true in C++ when up-to-date status of object changes
CADGeometry.sub_shape_selection_display_dataCAD face selection plot
CADGeometry.sub_shapesSub faces of the CAD geometry
CADGeometry.uidUID of object
CADGeometry.use_default_offsetWhether to use the default value or not
CADGeometry.use_default_precisionWhether to use default precision value or not
CADGeometry.vertexThis will throw an error if the object has been removed from the graph
CADGeometry.visible_sub_shapesIds of CAD sub shapes to be displayed, stored per-scene ID
CADGeometry.visualization_meshVisualization mesh of this geometry

Methods

NameDescription
CADGeometry.add_visible_sub_shapes(...)
CADGeometry.added_to_active_set(scene)
CADGeometry.clear_visible_sub_shapes(scene)
CADGeometry.find_parent(type)Steps up the tree and returns the first parent with given type
CADGeometry.get_face_ids_from_sub_shapes(...)
CADGeometry.get_faces_from_sub_shapes(sub_shapes)
CADGeometry.get_short_description()
CADGeometry.obj_exists()Checks if __obj still references the C++ object (i.e. has not been reset to None by self._delete) AND exists in the graph
CADGeometry.refresh_external_source([enforce])Reload the geometry from the external source
CADGeometry.remove_visible_sub_shapes(...)
CADGeometry.removed_from_active_set(scene)
CADGeometry.save_as(path)Save the initial geometry file to the specified path
CADGeometry.serialize()
CADGeometry.serialize_name_and_id()Helper function to serialize name and ID
CADGeometry.update()
CADGeometry.visit(visitor)Walk through the tree and let the visitor perform action on every descendant node
CADGeometry.visualization_normals(faces)