GXSURFACEITEM class¶
- class GXSURFACEITEM(handle=0)[source]¶
GXSURFACEITEM class.
The
GXSURFACEITEM
allows you to create, read and alter Geosurface files (*.geosoft_surface
). A Geosurface file can contain one or more surface items (seeGXSURFACE
class). A surface item can contains one or more triangular polyhedral meshes.- add_mesh(vert_v_vx, vert_v_vy, vert_v_vz, tri_vv_pt1, tri_vv_pt2, tri_vv_pt3)[source]¶
Adds a triangular polyhedral mesh component to the surface item.
- Parameters:
- Returns:
The index of the component added.
- Return type:
int
New in version 8.4.
License: Geosoft Open License
- compute_extended_info(components, vertices, edges, triangles, inconsistent, invalid, intersectiona)[source]¶
Compute more information (including validation) about of all mesh components in the surface item.
- Parameters:
components (int_ref) – Number of inner components (recomputed)
vertices (int_ref) – Total number of valid vertices
edges (int_ref) – Total number of valid edges
triangles (int_ref) – Total number of valid triangles
inconsistent (int_ref) – Number of inconsistent triangles
invalid (int_ref) – Number of invalid triangles
intersectiona (int_ref) – Number of self intersections
New in version 8.5.
License: Geosoft Open License
- compute_poly_line_intersections(vv_x, vv_y, vv_z, vv_x_out, vv_y_out, vv_z_out)[source]¶
Compute intersections of a 3D PolyLine with a
GXSURFACEITEM
Object- Parameters:
New in version 9.7.1.
License: Geosoft End-User License
- classmethod create(type, name)[source]¶
Create a
GXSURFACEITEM
- Parameters:
type (str) – Type
name (str) – Name
- Returns:
GXSURFACEITEM
Object- Return type:
New in version 8.4.
License: Geosoft Open License
See also
- get_default_render_properties(color, transparency, render_mode)[source]¶
Gets default render properties of the surface item.
- Parameters:
color (int_ref) – Color
transparency (float_ref) – Transparency
render_mode (int_ref) – SURFACERENDER_MODE constants
New in version 8.4.
License: Geosoft Open License
See also
- get_extents(min_x, min_y, min_z, max_x, max_y, max_z)[source]¶
Get the spatial range of the the surface item.
- Parameters:
New in version 8.5.
License: Geosoft Open License
- get_geometry_info(vertices, triangles)[source]¶
Get the total number of vertices and triangles of all mesh components in item.
- Parameters:
New in version 8.5.
License: Geosoft Open License
- get_guid(guid)[source]¶
Gets the GUID of the surface item.
- Parameters:
guid (str_ref) – GUID
New in version 8.4.
License: Geosoft Open License
Note: The value returned by this call will not be valid for newly created items until after a call to
GXSURFACE.add_surface_item
.
- get_info(closed, area, volume, volume_confidence_interval)[source]¶
Gets information about the surface item.
- Parameters:
New in version 8.5.
License: Geosoft Open License
- get_mesh(index, vert_v_vx, vert_v_vy, vert_v_vz, tri_vv_pt1, tri_vv_pt2, tri_vv_pt3)[source]¶
Gets a triangular polyhedral mesh of a component in the surface item.
- Parameters:
New in version 8.4.
License: Geosoft Open License
- get_mesh_info(index, closed, n_inner_comps, area, volume, volume_confidence_interval)[source]¶
Gets information about a triangular polyhedral mesh component in the surface item.
- Parameters:
New in version 8.4.
License: Geosoft Open License
- get_properties(type, name, source_guid, source_name, source_measure, secondary_source_guid, secondary_source_name, secondary_source_measure)[source]¶
Gets the properties of the surface item.
- Parameters:
type (str_ref) – Type
name (str_ref) – Name
source_guid (str_ref) – SourceGuid
source_name (str_ref) – SourceName
source_measure (float_ref) – SourceMeasure
secondary_source_guid (str_ref) – SecondarySourceGuid
secondary_source_name (str_ref) – SecondarySourceName
secondary_source_measure (float_ref) – SecondarySourceMeasure
New in version 8.4.
License: Geosoft Open License
- get_properties_ex(type, name, source_guid, source_name, source_measure, secondary_source_guid, secondary_source_name, secondary_source_option, secondary_source_measure, secondary_source_measure2)[source]¶
Gets the properties of the surface item (includes new properties introduced in 8.5).
- Parameters:
type (str_ref) – Type
name (str_ref) – Name
source_guid (str_ref) – SourceGuid
source_name (str_ref) – SourceName
source_measure (float_ref) – SourceMeasure
secondary_source_guid (str_ref) – SecondarySourceGuid
secondary_source_name (str_ref) – SecondarySourceName
secondary_source_option (int_ref) – SecondarySourceOption
secondary_source_measure (float_ref) – SecondarySourceMeasure
secondary_source_measure2 (float_ref) – SecondarySourceMeasure2
New in version 8.5.
License: Geosoft Open License
- intersects_bounding_box(min_x, min_y, min_z, max_x, max_y, max_z)[source]¶
Checks intersections of a bounding box with a
GXSURFACEITEM
Object- Parameters:
min_x (float) – Min X
min_y (float) – Min Y
min_z (float) – Min Z
max_x (float) – Max X
max_y (float) – Max Y
max_z (float) – Max Z
- Return type:
bool
New in version 9.7.1.
License: Geosoft End-User License
- is_null()[source]¶
Check if this is a null (undefined) instance
- Returns:
True if this is a null (undefined) instance, False otherwise.
- Return type:
bool
- classmethod null()[source]¶
A null (undefined) instance of
GXSURFACEITEM
- Returns:
A null
GXSURFACEITEM
- Return type:
- num_components()[source]¶
Get the number of components in the surface item.
- Returns:
Number of components in the surface item.
- Return type:
int
New in version 8.4.
License: Geosoft Open License
- set_default_render_properties(color, transparency, render_mode)[source]¶
Sets default render properties of the surface item.
- Parameters:
color (int) – Color
transparency (float) – Transparency
render_mode (int) – SURFACERENDER_MODE constants
New in version 8.4.
License: Geosoft Open License
See also
- set_properties(type, name, source_guid, source_name, source_measure, secondary_source_guid, secondary_source_name, secondary_source_measure)[source]¶
Sets the properties of the surface item.
- Parameters:
type (str) – Type
name (str) – Name
source_guid (str) – SourceGuid
source_name (str) – SourceName
source_measure (float) – SourceMeasure
secondary_source_guid (str) – SecondarySourceGuid
secondary_source_name (str) – SecondarySourceName
secondary_source_measure (float) – SecondarySourceMeasure
New in version 8.4.
License: Geosoft Open License
See also
- set_properties_ex(type, name, source_guid, source_name, source_measure, secondary_source_guid, secondary_source_name, secondary_source_option, secondary_source_measure, secondary_source_measure2)[source]¶
Sets the properties of the surface item (includes new properties introduced in 8.5).
- Parameters:
type (str) – Type
name (str) – Name
source_guid (str) – SourceGuid
source_name (str) – SourceName
source_measure (float) – SourceMeasure
secondary_source_guid (str) – SecondarySourceGuid
secondary_source_name (str) – SecondarySourceName
secondary_source_option (int) – SecondarySourceOption
secondary_source_measure (float) – SecondarySourceMeasure
secondary_source_measure2 (float) – SecondarySourceMeasure2
New in version 8.5.
License: Geosoft Open License
See also
SURFACERENDER_MODE constants¶
Open Modes