geosoft.gxpy.group

A Geosoft View (geosoft.gxpy.view.View or geosoft.gxpy.view.View_3d) contains graphical elements as Group instances. Groups are named and are available to a user in a Geosoft viewer, which allows groups to be turned on or off, modify the transparency, or be deleted.

2D views can only accept 2D groups, while a 3D view can accept both 2D and 3D groups. When a 2D group is placed in a 3D view, the group is placed on a the active plane inside the 3D view

Classes:
Group:

base class for named rendering groups in 2D and 3D views.

Draw:

2D drawing group, handles 2D drawing to a view or plane in a 3D view

Draw_3d:

3D grawing group for 3D objects placed in a 3d view

Color_symbols_group:

group for 2D symbols rendered based on data values

Aggregate_group:

group that contains a geosoft.gxpy.agg.Aggregate_image instance

Color:

colour definition

Color_map:

maps values to colors

Pen:

pen definition, includes line colour, thickness and pattern, and fill.

Text_def:

defined text characteristics

VoxDisplayGroup:

a ‘geosoft.gxpy.vox.VoxDisplay` in a geosoft.gxpy.view.View_3d

Constants:
GROUP_NAME_SIZE:

geosoft.gxpy.view.VIEW_NAME_SIZE

NEW:

geosoft.gxapi.MVIEW_GROUP_NEW

APPEND:

geosoft.gxapi.MVIEW_GROUP_APPEND

READ_ONLY:

max(NEW, APPEND) + 1

REPLACE:

READ_ONLY + 1

SMOOTH_NONE:

geosoft.gxapi.MVIEW_SMOOTH_NEAREST

SMOOTH_CUBIC:

geosoft.gxapi.MVIEW_SMOOTH_CUBIC

SMOOTH_AKIMA:

geosoft.gxapi.MVIEW_SMOOTH_AKIMA

TILE_RECTANGULAR:

geosoft.gxapi.MVIEW_TILE_RECTANGULAR

TILE_DIAGONAL:

geosoft.gxapi.MVIEW_TILE_DIAGONAL

TILE_TRIANGULAR:

geosoft.gxapi.MVIEW_TILE_TRIANGULAR

TILE_RANDOM:

geosoft.gxapi.MVIEW_TILE_RANDOM

UNIT_VIEW:

0

UNIT_MAP:

2

UNIT_VIEW_UNWARPED:

3

GRATICULE_DOT:

0

GRATICULE_LINE:

1

GRATICULE_CROSS:

2

LINE_STYLE_SOLID:

1

LINE_STYLE_LONG:

2

LINE_STYLE_DOTTED:

3

LINE_STYLE_SHORT:

4

LINE_STYLE_LONG_SHORT_LONG:

5

LINE_STYLE_LONG_DOT_LONG:

6

SYMBOL_NONE:

0

SYMBOL_DOT:

1

SYMBOL_PLUS:

2

SYMBOL_X:

3

SYMBOL_BOX:

4

SYMBOL_TRIANGLE:

5

SYMBOL_INVERTED_TRIANGLE:

6

SYMBOL_HEXAGON:

7

SYMBOL_SMALL_BOX:

8

SYMBOL_SMALL_DIAMOND:

9

SYMBOL_CIRCLE:

20

SYMBOL_3D_SPHERE:

0

SYMBOL_3D_CUBE:

1

SYMBOL_3D_CYLINDER:

2

SYMBOL_3D_CONE:

3

FONT_WEIGHT_ULTRALIGHT:

1

FONT_WEIGHT_LIGHT:

2

FONT_WEIGHT_MEDIUM:

3

FONT_WEIGHT_BOLD:

4

FONT_WEIGHT_XBOLD:

5

FONT_WEIGHT_XXBOLD:

6

CMODEL_RGB:

0

CMODEL_CMY:

1

CMODEL_HSV:

2

C_BLACK:

67108863

C_RED:

33554687

C_GREEN:

33619712

C_BLUE:

50266112

C_CYAN:

50331903

C_MAGENTA:

50396928

C_YELLOW:

67043328

C_GREY:

41975936

C_LT_RED:

54542336

C_LT_GREEN:

54526016

C_LT_BLUE:

50348096

C_LT_CYAN:

50331712

C_LT_MAGENTA:

50348032

C_LT_YELLOW:

54525952

C_LT_GREY:

54542400

C_GREY10:

51910680

C_GREY25:

54542400

C_GREY50:

41975936

C_WHITE:

50331648

C_TRANSPARENT:

0

REF_BOTTOM_LEFT:

0

REF_BOTTOM_CENTER:

1

REF_BOTTOM_RIGHT:

2

REF_CENTER_LEFT:

3

REF_CENTER:

4

REF_CENTER_RIGHT:

5

REF_TOP_LEFT:

6

REF_TOP_CENTER:

7

REF_TOP_RIGHT:

8

GROUP_ALL:

0

GROUP_MARKED:

1

GROUP_VISIBLE:

2

GROUP_AGG:

3

GROUP_CSYMB:

4

GROUP_VOXD:

5

LOCATE_FIT:

geosoft.gxapi.MVIEW_RELOCATE_FIT

LOCATE_FIT_KEEP_ASPECT:

geosoft.gxapi.MVIEW_RELOCATE_ASPECT

LOCATE_CENTER:

geosoft.gxapi.MVIEW_RELOCATE_ASPECT_CENTER

COLOR_BAR_RIGHT:

0

COLOR_BAR_LEFT:

1

COLOR_BAR_BOTTOM:

2

COLOR_BAR_TOP:

3

COLOR_BAR_ANNOTATE_RIGHT:

1

COLOR_BAR_ANNOTATE_LEFT:

-1

COLOR_BAR_ANNOTATE_TOP:

1

COLOR_BAR_ANNOTATE_BOTTOM:

-1

CYLINDER_OPEN:

0

CYLINDER_CLOSE_START:

1

CYLINDER_CLOSE_END:

2

CYLINDER_CLOSE_ALL:

3

POINT_STYLE_DOT:

0

POINT_STYLE_SPHERE:

1

LINE3D_STYLE_LINE:

0

LINE3D_STYLE_TUBE:

1

LINE3D_STYLE_TUBE_JOINED:

2

SURFACE_FLAT:

geosoft.gxapi.MVIEW_DRAWOBJ3D_MODE_FLAT

SURFACE_SMOOTH:

geosoft.gxapi.MVIEW_DRAWOBJ3D_MODE_SMOOTH

Note

Regression tests provide usage examples: group drawing tests

Functions

_draw(func)

_make_point(p)

_make_point2(p2)

_make_ppoint(p)

_t(s)

color_from_string(cstr)

Return a Geosoft color number from a color string.

contour(view, group_name, grid_file_name[, ...])

Create a contour group from a grid file.

edge_reference(area, reference)

Location of a reference point of an area.

face_normals_np(faces, verticies)

Return normals of the verticies based on tringular faces, assuming right-hand winding of vertex for each face.

font_weight_from_line_thickness(line_thick, ...)

Returns font weight for a text height and line thickness.

legend_color_bar(view, group_name, cmap[, ...])

Draw a color bar legend from :class:Color_map coloring definitions.

surface_group_from_file(v3d, file_name[, ...])

Create a 3D surface group from a surface dataset file.

thickness_from_font_weight(weight, height)

Returns the line thickness appropriate for a text weight.

vertex_normals_np(faces, verticies[, ...])

Return normals of the verticies based on tringular faces, assuming right-hand winding of vertex for each face.

vertex_normals_vv(faces, verticies[, ...])

Return normals of the verticies based on tringular faces, assuming right-hand winding of vertex for each face.

Classes

Aggregate_group(view, group_name, mode)

Aggregate group in a view

Color(color[, model])

Colours, which are stored as a 32-bit color integer.

Color_map([cmap, title, unit_of_measure])

Color map for establishing data color mapping for things like aggregates and color symbols.

Color_symbols_group(view, group_name, **kwargs)

Data represented as colored symbols based on a Color_map.

Draw(*args, **kwargs)

Create (start) a drawing group for 2D drawing elements.

Draw_3d(view, *args[, render_backfaces])

Create a 3D drawing group within a 3D view.

Group(view[, name, plane, view_lock, mode, ...])

Geosoft group class.

Pen(**kwargs)

Geosoft Pen class.

Text_def(**kwargs)

Text definition:

VoxDisplayGroup(view3d, group_name[, mode])

Vox display group in a view. Use class methods new() and open()

Exceptions

GroupException(message)

Exceptions from geosoft.gxpy.group.