|
Cubit Python API 2026.6
|
The base class for specifically the Geometry types (Body, Surface, etc.) More...
Public Member Functions | |
| bodies (self) | |
| Retrieve bodies contained within the geometry entity. | |
| curves (self) | |
| Retrieve curves (edges) associated with the geometry entity. | |
| dimension (self) | |
| Get the topological dimension of the geometry entity. | |
| entity_name (self) | |
| Retrieve the primary name of the geometry entity. | |
| entity_names (self) | |
| Retrieve all names assigned to the geometry entity. | |
| is_meshed (self) | |
| Returns the current mesh state of the GeomEntity. | |
| is_transparent (self) | |
| Get the transparency state of the geometry entity. | |
| is_visible (self) | |
| Get the visibility state of the geometry entity. | |
| mesh (self) | |
| Generates mesh on a GeomEntity and verifies meshing status. | |
| num_names (self) | |
| Get the count of names assigned to the geometry entity. | |
| remove_entity_name (self, name) | |
| Remove a specific name from the geometry entity. | |
| remove_entity_names (self) | |
| Remove all non-default names from the geometry entity. | |
| remove_mesh (self) | |
| Remove any mesh associated with the geometry entity. | |
| set_entity_name (self, name) | |
| Assign a name to the geometry entity. | |
| set_transparent (self, transparency_flag) | |
| Set the transparency state of the geometry entity. | |
| set_visible (self, visibility_flag) | |
| Set and verify the visibility state of the geometry entity. | |
| smooth (self) | |
| Smooths the mesh on a GeomEntity to improve element quality. | |
| surfaces (self) | |
| Retrieve surfaces associated with the geometry entity. | |
| vertices (self) | |
| Retrieve vertices (points) associated with the geometry entity. | |
| volumes (self) | |
| Retrieve volumes associated with the geometry entity. | |
Public Member Functions inherited from Entity | |
| bounding_box (self) | |
| Returns the axis-aligned bounding box of the Entity. | |
| center_point (self) | |
| Returns the geometric center point of the Entity. | |
| id (self) | |
| Retrieves the unique identifier of the Entity. | |
Detailed Description
Member Function Documentation
◆ bodies()
| bodies | ( | self | ) |
Retrieve bodies contained within the geometry entity.
Returns a list of Body objects associated with this GeomEntity, such as sheet bodies from a surface or volumes from a body.
.. code-block:: python
@n return type of : std::vector< CubitInterface::Body,std::allocator< CubitInterface:: Body > >
- Returns
- A vector (list) of Body objects contained within the GeomEntity.
◆ curves()
| curves | ( | self | ) |
Retrieve curves (edges) associated with the geometry entity.
Returns a list of Curve objects that bound this GeomEntity, such as the edges of a brick or boundary curves of surfaces.
.. code-block:: python
@n return type of : std::vector< CubitInterface::Curve,std::allocator< CubitInterface:: Curve > >
- Returns
- A vector (list) of Curve objects associated with this GeomEntity.
◆ dimension()
| dimension | ( | self | ) |
Get the topological dimension of the geometry entity.
Returns the dimension (0 for Vertex, 1 for Curve, 2 for Surface, 3 for Volume/Body) of this GeomEntity.
.. code-block:: python
for c in curves: print("Curve dimension:", c.dimension()) # Expected output: 1
@n return type of : int
- Returns
- The topological dimension of the GeomEntity (0x3).
◆ entity_name()
| entity_name | ( | self | ) |
Retrieve the primary name of the geometry entity.
Returns the first name assigned to this GeomEntity, useful for identification and labeling.
.. code-block:: python
@n return type of : string
- Returns
- The first name of the GeomEntity.
◆ entity_names()
| entity_names | ( | self | ) |
Retrieve all names assigned to the geometry entity.
Returns a list of every name that has been assigned to this GeomEntity, allowing enumeration of aliases or prior identifiers.
.. code-block:: python
for n in names: print("Name:", n)
@n return type of : std::vector< std::string,std::allocator< std:: string > >
- Returns
- A vector (list) of all names assigned to the GeomEntity.
◆ is_meshed()
| is_meshed | ( | self | ) |
Returns the current mesh state of the GeomEntity.
Indicates whether the GeomEntity has mesh elements defined.
.. code-block:: python
@n return type of : boolean
- Returns
- True if the GeomEntity is meshed, false otherwise.
◆ is_transparent()
| is_transparent | ( | self | ) |
Get the transparency state of the geometry entity.
Returns whether this GeomEntity is currently rendered as transparent (`1`) or opaque (`0`).
.. code-block:: python
@n return type of : int
- Returns
- The current transparency state of the GeomEntity (
1if transparent,0if opaque).
◆ is_visible()
| is_visible | ( | self | ) |
Get the visibility state of the geometry entity.
Returns whether this GeomEntity is currently visible in the viewport (1) or hidden (0).
.. code-block:: python
@n return type of : int
- Returns
- The current visibility state of the GeomEntity (1 if visible, 0 if hidden).
◆ mesh()
| mesh | ( | self | ) |
Generates mesh on a GeomEntity and verifies meshing status.
Discretizes the geometry of the given GeomEntity (e.g., surface, volume) into mesh elements. Use ``is_meshed`` to verify if meshing has been performed on the entity.
.. code-block:: python
◆ num_names()
| num_names | ( | self | ) |
Get the count of names assigned to the geometry entity.
Returns the number of names currently assigned to this GeomEntity for tracking aliases or identifiers.
.. code-block:: python
@n return type of : int
- Returns
- The number of names assigned to the GeomEntity.
◆ remove_entity_name()
| remove_entity_name | ( | self, | |
| name ) |
Remove a specific name from the geometry entity.
Deletes one of the names previously assigned to this GeomEntity, preserving any other names.
.. code-block:: python
for n in names: print("Remaining name:", n)
@n type of name: string, in
- Parameters
-
name The specific name to remove from this GeomEntity.
◆ remove_entity_names()
| remove_entity_names | ( | self | ) |
Remove all non-default names from the geometry entity.
Deletes every custom name assigned to this GeomEntity, preserving its inherent default name.
.. code-block:: python
◆ remove_mesh()
| remove_mesh | ( | self | ) |
Remove any mesh associated with the geometry entity.
Deletes the mesh on a GeomEntity
.. code-block:: python
◆ set_entity_name()
| set_entity_name | ( | self, | |
| name ) |
Assign a name to the geometry entity.
Sets the primary name of this GeomEntity for identification and labeling.
.. code-block:: python
@n type of name: string, in
- Parameters
-
name The name to be assigned to the GeomEntity.
◆ set_transparent()
| set_transparent | ( | self, | |
| transparency_flag ) |
Set the transparency state of the geometry entity.
Toggles whether this GeomEntity is rendered with transparency. Passing `1` makes it transparent; `0` makes it opaque. The default state upon creation is transparent.
.. code-block:: python
@n type of transparency_flag: int, in
- Parameters
-
transparency_flag The flag ( 1for transparent,0for opaque) to set the render transparency state.
◆ set_visible()
| set_visible | ( | self, | |
| visibility_flag ) |
Set and verify the visibility state of the geometry entity.
Toggles whether this GeomEntity is rendered in the viewport. Passing `true` makes it visible; `false` hides it. Use `is_visible()` to query the current state.
.. code-block:: python
@n type of visibility_flag: boolean, in
- Parameters
-
visibility_flag The flag to set whether the Entity is visible ( true) or hidden (false).
◆ smooth()
| smooth | ( | self | ) |
Smooths the mesh on a GeomEntity to improve element quality.
Applies mesh smoothing to the existing mesh on the GeomEntity. Requires that the entity has already been meshed (`is_meshed()` returns true). Smoothing method is based on the scheme currently set on the geomEntity (ie. Laplacian, Mean Ratio, etc.)
.. code-block:: python
◆ surfaces()
| surfaces | ( | self | ) |
Retrieve surfaces associated with the geometry entity.
Returns a list of Surface objects that bound this GeomEntity, such as the faces of a brick.
.. code-block:: python
@n return type of : std::vector< CubitInterface::Surface,std::allocator< CubitInterface:: Surface > >
- Returns
- A vector (list) of Surface objects associated with this GeomEntity.
◆ vertices()
| vertices | ( | self | ) |
Retrieve vertices (points) associated with the geometry entity.
Returns a list of Vertex objects that bound this GeomEntity, such as the corners of a brick.
.. code-block:: python
@n return type of : std::vector< CubitInterface::Vertex,std::allocator< CubitInterface:: Vertex > >
- Returns
- A vector (list) of Vertex objects associated with this GeomEntity.
◆ volumes()
| volumes | ( | self | ) |
Retrieve volumes associated with the geometry entity.
Returns a list of Volume objects associated with this GeomEntity, such as the volume created by a brick.
.. code-block:: python
@n return type of : std::vector< CubitInterface::Volume,std::allocator< CubitInterface:: Volume > >
- Returns
- A vector (list) of Volume objects associated with this GeomEntity.
Generated on Tue Jun 9 2026 13:00:43 for Cubit Python API by
Public Member Functions inherited from