wx_BGI_Graphics
Classic BGI-compatible graphics API with modern OpenGL extension API
Loading...
Searching...
No Matches
Functions
Visual Overlay API

Functions

BGI_API void BGI_CALL wxbgi_overlay_concentric_disable (const char *camName)
 Disable the concentric circles overlay for a camera.
 
BGI_API void BGI_CALL wxbgi_overlay_concentric_enable (const char *camName)
 Enable the concentric circles overlay for a camera.
 
BGI_API int BGI_CALL wxbgi_overlay_concentric_is_enabled (const char *camName)
 Return 1 if the concentric circles overlay is enabled for a camera.
 
BGI_API void BGI_CALL wxbgi_overlay_concentric_set_count (const char *camName, int count)
 Set the number of concentric circles.
 
BGI_API void BGI_CALL wxbgi_overlay_concentric_set_radii (const char *camName, float innerRadius, float outerRadius)
 Set the inner and outer world-unit radii for the circles.
 
BGI_API void BGI_CALL wxbgi_overlay_cursor_disable (const char *camName)
 Disable the selection cursor square overlay for a camera.
 
BGI_API void BGI_CALL wxbgi_overlay_cursor_enable (const char *camName)
 Enable the selection cursor square overlay for a camera.
 
BGI_API int BGI_CALL wxbgi_overlay_cursor_is_enabled (const char *camName)
 Return 1 if the selection cursor is enabled for a camera.
 
BGI_API void BGI_CALL wxbgi_overlay_cursor_set_color (const char *camName, int colorScheme)
 Set the colour scheme of the selection cursor.
 
BGI_API void BGI_CALL wxbgi_overlay_cursor_set_size (const char *camName, int sizePx)
 Set the side length of the selection cursor square.
 
BGI_API void BGI_CALL wxbgi_overlay_grid_disable (void)
 Disable the reference grid overlay.
 
BGI_API void BGI_CALL wxbgi_overlay_grid_enable (void)
 Enable the reference grid overlay.
 
BGI_API int BGI_CALL wxbgi_overlay_grid_is_enabled (void)
 Return 1 if the grid overlay is enabled, 0 otherwise.
 
BGI_API void BGI_CALL wxbgi_overlay_grid_set_colors (int xAxisColor, int yAxisColor, int gridColor)
 Set the three colours used by the grid overlay.
 
BGI_API void BGI_CALL wxbgi_overlay_grid_set_extent (int halfExtentInLines)
 Set the grid extent.
 
BGI_API void BGI_CALL wxbgi_overlay_grid_set_spacing (float worldUnits)
 Set the spacing between adjacent grid lines.
 
BGI_API void BGI_CALL wxbgi_overlay_grid_set_ucs (const char *ucsName)
 Bind the grid to a specific UCS.
 
BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_disable (void)
 Disable the UCS axes overlay.
 
BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_enable (void)
 Enable the UCS axes overlay.
 
BGI_API int BGI_CALL wxbgi_overlay_ucs_axes_is_enabled (void)
 Return 1 if the UCS axes overlay is enabled, 0 otherwise.
 
BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_set_length (float worldUnits)
 Set the length of each axis arm.
 
BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_show_active (int show)
 Show or hide the active UCS axes (at the active UCS origin).
 
BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_show_world (int show)
 Show or hide the world UCS axes (at the world origin).
 
BGI_API void BGI_CALL wxbgi_selection_clear (void)
 Clear all currently selected objects (does not delete them from the DDS).
 
BGI_API int BGI_CALL wxbgi_selection_count (void)
 Return the number of currently selected DDS objects.
 
BGI_API void BGI_CALL wxbgi_selection_delete_selected (void)
 Delete all currently selected objects from the DDS and clear the selection.
 
BGI_API const char *BGI_CALL wxbgi_selection_get_id (int index)
 Return the ID string of the index-th selected object (0-based).
 
BGI_API void BGI_CALL wxbgi_selection_set_flash_scheme (int scheme)
 Set the selection flash colour scheme.
 
BGI_API void BGI_CALL wxbgi_selection_set_pick_radius (int pixels)
 Set the screen-pixel pick radius for object selection.
 

Detailed Description

Function Documentation

◆ wxbgi_overlay_concentric_disable()

BGI_API void BGI_CALL wxbgi_overlay_concentric_disable ( const char *  camName)

Disable the concentric circles overlay for a camera.

Parameters
camNameCamera name; NULL or "" = active camera.

◆ wxbgi_overlay_concentric_enable()

BGI_API void BGI_CALL wxbgi_overlay_concentric_enable ( const char *  camName)

Enable the concentric circles overlay for a camera.

World-space circles are drawn centred at the camera's pan centre (2-D cameras) or target point (3-D cameras). Because the radii are in world units, the pixel spacing grows/shrinks as you zoom in/out. A crosshair through the centre rotates with the camera for 2-D cameras.

Parameters
camNameCamera name; NULL or "" = active camera.

◆ wxbgi_overlay_concentric_is_enabled()

BGI_API int BGI_CALL wxbgi_overlay_concentric_is_enabled ( const char *  camName)

Return 1 if the concentric circles overlay is enabled for a camera.

Parameters
camNameCamera name; NULL or "" = active camera.

◆ wxbgi_overlay_concentric_set_count()

BGI_API void BGI_CALL wxbgi_overlay_concentric_set_count ( const char *  camName,
int  count 
)

Set the number of concentric circles.

Parameters
camNameCamera name; NULL or "" = active camera.
countNumber of circles (clamped to 1..8). Default: 3.

◆ wxbgi_overlay_concentric_set_radii()

BGI_API void BGI_CALL wxbgi_overlay_concentric_set_radii ( const char *  camName,
float  innerRadius,
float  outerRadius 
)

Set the inner and outer world-unit radii for the circles.

Parameters
camNameCamera name; NULL or "" = active camera.
innerRadiusWorld-unit radius of the innermost circle (>= 0). Default: 25.
outerRadiusWorld-unit radius of the outermost circle (>= innerRadius). Default: 100.

◆ wxbgi_overlay_cursor_disable()

BGI_API void BGI_CALL wxbgi_overlay_cursor_disable ( const char *  camName)

Disable the selection cursor square overlay for a camera.

Parameters
camNameCamera name; NULL or "" = active camera.

◆ wxbgi_overlay_cursor_enable()

BGI_API void BGI_CALL wxbgi_overlay_cursor_enable ( const char *  camName)

Enable the selection cursor square overlay for a camera.

A small square follows the mouse within the camera's viewport. Its border alternates every 2 seconds between the light and dark shade of the chosen colour scheme.

Parameters
camNameCamera name; NULL or "" = active camera.

◆ wxbgi_overlay_cursor_is_enabled()

BGI_API int BGI_CALL wxbgi_overlay_cursor_is_enabled ( const char *  camName)

Return 1 if the selection cursor is enabled for a camera.

Parameters
camNameCamera name; NULL or "" = active camera.

◆ wxbgi_overlay_cursor_set_color()

BGI_API void BGI_CALL wxbgi_overlay_cursor_set_color ( const char *  camName,
int  colorScheme 
)

Set the colour scheme of the selection cursor.

The cursor alternates between a light and dark shade of the chosen colour.

Parameters
camNameCamera name; NULL or "" = active camera.
colorScheme0 = blue (default), 1 = green, 2 = red.

◆ wxbgi_overlay_cursor_set_size()

BGI_API void BGI_CALL wxbgi_overlay_cursor_set_size ( const char *  camName,
int  sizePx 
)

Set the side length of the selection cursor square.

Parameters
camNameCamera name; NULL or "" = active camera.
sizePxSide length in pixels (clamped to 2..16). Default: 8.

◆ wxbgi_overlay_grid_disable()

BGI_API void BGI_CALL wxbgi_overlay_grid_disable ( void  )

Disable the reference grid overlay.

◆ wxbgi_overlay_grid_enable()

BGI_API void BGI_CALL wxbgi_overlay_grid_enable ( void  )

Enable the reference grid overlay.

The grid is drawn in the XY plane of the active UCS (or the UCS set by wxbgi_overlay_grid_set_ucs()) and is visible in every camera viewport.

◆ wxbgi_overlay_grid_is_enabled()

BGI_API int BGI_CALL wxbgi_overlay_grid_is_enabled ( void  )

Return 1 if the grid overlay is enabled, 0 otherwise.

◆ wxbgi_overlay_grid_set_colors()

BGI_API void BGI_CALL wxbgi_overlay_grid_set_colors ( int  xAxisColor,
int  yAxisColor,
int  gridColor 
)

Set the three colours used by the grid overlay.

Parameters
xAxisColorColour for the line along UCS local X (default: RED).
yAxisColorColour for the line along UCS local Y (default: GREEN).
gridColorColour for all other grid lines (default: DARKGRAY).

◆ wxbgi_overlay_grid_set_extent()

BGI_API void BGI_CALL wxbgi_overlay_grid_set_extent ( int  halfExtentInLines)

Set the grid extent.

The grid spans from -(halfExtentInLines * spacing) to +(halfExtentInLines * spacing) from the UCS origin in both UCS X and Y.

Parameters
halfExtentInLinesNumber of lines on each side of the origin (must be >= 1). Default: 4.

◆ wxbgi_overlay_grid_set_spacing()

BGI_API void BGI_CALL wxbgi_overlay_grid_set_spacing ( float  worldUnits)

Set the spacing between adjacent grid lines.

Parameters
worldUnitsDistance between lines in world units (must be > 0). Default: 25.

◆ wxbgi_overlay_grid_set_ucs()

BGI_API void BGI_CALL wxbgi_overlay_grid_set_ucs ( const char *  ucsName)

Bind the grid to a specific UCS.

Parameters
ucsNameName of the UCS whose XY plane the grid follows. Pass NULL or "" to use the active UCS (default).

◆ wxbgi_overlay_ucs_axes_disable()

BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_disable ( void  )

Disable the UCS axes overlay.

◆ wxbgi_overlay_ucs_axes_enable()

BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_enable ( void  )

Enable the UCS axes overlay.

Draws labelled X (RED), Y (GREEN), Z (BLUE) axis arms at the world origin and/or the active UCS origin in every camera viewport.

◆ wxbgi_overlay_ucs_axes_is_enabled()

BGI_API int BGI_CALL wxbgi_overlay_ucs_axes_is_enabled ( void  )

Return 1 if the UCS axes overlay is enabled, 0 otherwise.

◆ wxbgi_overlay_ucs_axes_set_length()

BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_set_length ( float  worldUnits)

Set the length of each axis arm.

Parameters
worldUnitsLength from the UCS origin to the axis tip (must be > 0). Default: 80.

◆ wxbgi_overlay_ucs_axes_show_active()

BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_show_active ( int  show)

Show or hide the active UCS axes (at the active UCS origin).

Parameters
showNon-zero to show, 0 to hide. Default: shown.

◆ wxbgi_overlay_ucs_axes_show_world()

BGI_API void BGI_CALL wxbgi_overlay_ucs_axes_show_world ( int  show)

Show or hide the world UCS axes (at the world origin).

Parameters
showNon-zero to show, 0 to hide. Default: shown.

◆ wxbgi_selection_clear()

BGI_API void BGI_CALL wxbgi_selection_clear ( void  )

Clear all currently selected objects (does not delete them from the DDS).

◆ wxbgi_selection_count()

BGI_API int BGI_CALL wxbgi_selection_count ( void  )

Return the number of currently selected DDS objects.

◆ wxbgi_selection_delete_selected()

BGI_API void BGI_CALL wxbgi_selection_delete_selected ( void  )

Delete all currently selected objects from the DDS and clear the selection.

Each object is soft-deleted via DdsScene::remove() and the scene is compacted. This is irreversible without resetting the DDS.

◆ wxbgi_selection_get_id()

BGI_API const char *BGI_CALL wxbgi_selection_get_id ( int  index)

Return the ID string of the index-th selected object (0-based).

Returns "" if index is out of range. The returned pointer is valid only until the next selection mutation or library call.

◆ wxbgi_selection_set_flash_scheme()

BGI_API void BGI_CALL wxbgi_selection_set_flash_scheme ( int  scheme)

Set the selection flash colour scheme.

Parameters
scheme0 = orange (default), 1 = purple.

◆ wxbgi_selection_set_pick_radius()

BGI_API void BGI_CALL wxbgi_selection_set_pick_radius ( int  pixels)

Set the screen-pixel pick radius for object selection.

A left-click selects the nearest DDS object whose projected geometry falls within pixels screen pixels of the cursor centre. Default: 12. Clamped to the range [2, 64].