This page has been translated automatically.
Video Tutorials
Interface
Essentials
Advanced
How To
Professional (SIM)
UnigineEditor
Interface Overview
Assets Workflow
Settings and Preferences
Working With Projects
Adjusting Node Parameters
Setting Up Materials
Setting Up Properties
Lighting
Sandworm
Using Editor Tools for Specific Tasks
Extending Editor Functionality
Built-in Node Types
Nodes
Objects
Effects
Decals
Light Sources
Geodetics
World Nodes
Sound Objects
Pathfinding Objects
Players
Programming
Fundamentals
Setting Up Development Environment
Usage Examples
C++
C#
UnigineScript
UUSL (Unified UNIGINE Shader Language)
Plugins
File Formats
Materials and Shaders
Rebuilding the Engine Tools
GUI
Double Precision Coordinates
API
Containers
Common Functionality
Controls-Related Classes
Engine-Related Classes
Filesystem Functionality
GUI-Related Classes
Math Functionality
Node-Related Classes
Objects-Related Classes
Networking Functionality
Pathfinding-Related Classes
Physics-Related Classes
Plugins-Related Classes
IG Plugin
CIGIConnector Plugin
Rendering-Related Classes
Content Creation
Content Optimization
Materials
Material Nodes Library
Miscellaneous
Input
Math
Matrix
Textures
Art Samples
Tutorials
Warning! This version of documentation is OUTDATED, as it describes an older SDK version! Please switch to the documentation for the latest SDK version.
Warning! This version of documentation describes an old SDK version which is no longer supported! Please upgrade to the latest SDK version.

Unigine::Plugins::IG::Manager Class

Warning
The functionality described in this article is not available in the Community SDK edition.
You should upgrade to Sim SDK edition to use it.
Header: #include <plugins/UnigineIG.h>

This class represents the IG Manager interface.

Notice
IG plugin must be loaded.

Manager Class

Enums

DEBUG_MODE#

NameDescription
DEBUG_MODE_REQUEST_DEBUG = 0Debug mode visualizing where LOS/HAT/HOT requests are sent to.
DEBUG_MODE_ENTITY_PATH_TRACE = 1Debug mode with entity path tracing - positions between frames and data sent over the network. Blue points mark data from the server; pink arrows - movement between frames.
DEBUG_MODE_ENTITY_PATH_TRACE_TIME = 2Debug mode visualizing entity path tracing time.
DEBUG_MODE_ENTITY_COLLISION_SEGMENT = 3Debug mode visualizing collision segments for every entity.
DEBUG_MODE_ENTITY_COLLISION_VOLUME = 4Debug mode visualizing collision volumes for every entity.
DEBUG_MODE_ENTITY_INFO = 5Debug mode visualizing the basis for every CIGI and DIS entity with the ID, type, and type name specified (information is taken from the IG configuration file).
DEBUG_MODE_METEO = 6Debug mode visualizing meteo information.

Members


IGConfig * getConfig ( ) const#

Returns the IG configuration as an IGConfig class instance.

Return value

IGConfig class instance containing IG configuration.

void reloadConfig ( ) #

Reloads the IG Configuration file (ig_config.xml).

bool loadDatabase ( int database_id ) #

Loads the database with the specified ID and sets it to be used.

Arguments

  • int database_id - ID of the database to be used.

Return value

true means that the database with the specified ID is loaded successfully; otherwise, false.

void reloadDatabase ( ) #

Console: database_reload
Reloads the current database.

void unloadDatabase ( ) #

Unloads the current database.

int getCurrentDatabaseID ( ) const#

Returns the identifier of the currently loaded world database stored in the IG configuration file (ig_config.xml).

Return value

Identifier of the world database, or 0, if no world is loaded.

int getDatabaseID ( const char * world_name ) const#

Returns the identifier of the world database with the specified name stored in the IG configuration file (ig_config.xml).

Arguments

  • const char * world_name - World database name.

Return value

Identifier of the specified world database, or 0, if no world is loaded.

const char * getDatabaseName ( int id ) const#

Returns the name of the world database stored in the IG configuration file (ig_config.xml).

Arguments

  • int id - Identifier of the world database.

Return value

The world database name.

bool isDatabaseLoaded ( ) const#

Returns a value indicating if any database is currently loaded.

Return value

true if any database is currently loaded; otherwise, false.

SkyMap * getSkyMap ( ) const#

Returns the interface of the sky map.

Return value

Sky map interface.

Meteo * getMeteo ( ) const#

Returns the meteo interface.

Return value

Meteo interface.

SymbolsController * getSymbolsController ( ) const#

Returns the interface of the symbols controller.

Return value

Symbols controller interface.

LightController * getLightController ( ) const#

Returns the interface of the light controller.

Return value

Light controller interface.

Converter * getConverter ( ) const#

Returns the converter interface.

Return value

Converter interface.

View * getView ( int view_id, bool auto_create ) #

Returns the interface of the specified view.

Arguments

  • int view_id - ID of the view.
  • bool auto_create - true to automatically create the view with the specified ID if it doesn't exist yet; false - to return nullptr in case the view doesn't exist.

Return value

Pointer to the view interface if it exists; otherwise - nullptr.

void getViews ( Unigine::Vector < View *> & views_ret ) const#

Returns the list of all existing views (if any).

Arguments

  • Unigine::Vector < View *> & views_ret - Vector containing all existing views (if any).

bool removeView ( int view_id ) #

Removes the view with the specified ID.

Arguments

  • int view_id - ID of the view to be removed.

Return value

true if the view with the specified ID is removed successfully; otherwise - false.

bool isViewExist ( int view_id ) const#

Returns a value indicating if the view with the specified ID exists.

Arguments

  • int view_id - ID of the view.

Return value

true if the view with the specified ID exists; otherwise - false.

ViewGroup * getViewGroup ( int group_id, bool auto_create ) #

Returns the interface of the specified view group.

Arguments

  • int group_id - ID of the view group.
  • bool auto_create - true to automatically create the view group with the specified ID if it doesn't exist yet; false - to return nullptr in case the view group doesn't exist.

Return value

Pointer to the view group interface if it exists; otherwise - nullptr.

bool removeViewGroup ( int group_view_id ) #

Removes the view group with the specified ID.

Arguments

  • int group_view_id - ID of the view group to be removed.

Return value

true if the view group with the specified ID is removed successfully; otherwise - false.

bool isViewGroupExist ( int group_view_id ) const#

Returns a value indicating if the view group with the specified ID exists.

Arguments

  • int group_view_id - ID of the view group.

Return value

true if the view group with the specified ID exists; otherwise - false.

Entity * getEntity ( long long entity_id, bool auto_create = true ) #

Returns the interface of the specified entity.

Arguments

  • long long entity_id - ID of the entity.
    Notice
    The value should be the entity ID, not the type ID.
  • bool auto_create - true to automatically create the entity with the specified ID if it doesn't exist yet; false - to return nullptr in case the entity doesn't exist.

Return value

Pointer to the entity interface.

bool removeEntity ( long long entity_id ) #

Removes the entity with the specified ID.

Arguments

  • long long entity_id - ID of the entity to be removed.
    Notice
    The value should be the entity ID, not the type ID.

Return value

true if the entity with the specified ID is removed successfully; otherwise - false.

bool isEntityExist ( long long entity_id ) const#

Returns a value indicating if the entity with the specified ID exists.

Arguments

  • long long entity_id - ID of the entity.
    Notice
    The value should be the entity ID, not the type ID.

Return value

true if the entity with the specified ID exists; otherwise - false.

void getEntities ( Unigine::Vector<Entity *> & entities_ret ) const#

Fills the list of entities with all existing entities.

Arguments

  • Unigine::Vector<Entity *> & entities_ret - List of entities.

Entity * findEntity ( const Ptr<Node> & node ) const#

Returns the interface of the entity represented by the specified node.

Arguments

  • const Ptr<Node> & node - Node for which an entity is to be found.

Return value

Pointer to the entity interface if it exists; otherwise - nullptr.

long long findEntityType ( const char * type_name ) const#

Returns the ID of the entity type by its name. Entity type ID and name define the type of the entity to be used for a specific instance and are set in the entity definition section of the IG configuration file as follows:
Source code (XML)
<entity_types>
	<entity id="111" name="b52">
	</entity>
</entity_types>

Arguments

  • const char * type_name - Entity type name.

Return value

Entity type ID.

int findComponentID ( long long entity_type, const char * name ) const#

Returns the ID of the component with the given name, which belongs to the specified entity type.

Arguments

  • long long entity_type - Entity type ID.
    Notice
    Entity type ID is defined in the entity definition section of the IG configuration file.
  • const char * name - Component name.

Return value

Component ID.

int findArticulatedPartID ( long long entity_type, const char * name ) const#

Returns the identifier of an articulated part by its name and the type of the entity it belongs to, stored in the IG configuration file (ig_config.xml).

Arguments

  • long long entity_type - Entity type identifier indicated in the IG configuration file (ig_config.xml).
  • const char * name - Name of an articulated part indicated in the IG configuration file (ig_config.xml).

Return value

Identifier of an articulated part.

void setInterpolation ( bool enabled ) #

Sets a value indicating if interpolation and extrapolation should be enabled for the IG.

Arguments

bool isInterpolation ( ) const#

Returns a value indicating if interpolation and extrapolation are enabled for the IG.

Return value

true if interpolation and extrapolation are enabled for the IG; otherwise, false.

void setInterpolationLerp ( bool enabled ) #

Sets a value indicating if interpolation between the current and previous frames should be enabled for the IG to tackle the problem of lost packets between the IG and hosts.

Arguments

  • bool enabled - true to enable interpolation between the current and previous frames for the IG; false - to disable.

bool isInterpolationLerp ( ) const#

Returns a value indicating if interpolation between the current and previous frames is enabled for the IG to tackle the problem of lost packets between the IG and hosts.

Return value

true if interpolation between the current and previous frames is enabled for the IG; otherwise, false.

void setInterpolationTime ( double current_time ) #

Sets the interpolation time value for the IG.

Arguments

  • double current_time - Current interpolation time value, in seconds.

double getInterpolationTime ( ) const#

Returns the current interpolation time value for the IG.

Return value

Interpolation time value, in seconds.

void setInterpolationPeriod ( double time_period ) #

Sets the interpolation period value for the IG.

Arguments

  • double time_period - Interpolation period value, in seconds. The default value is 0.04.

double getInterpolationPeriod ( ) const#

Returns the current interpolation period value for the IG.

Return value

Interpolation period value, in seconds. The default value is 0.04.

void setExtrapolationPeriod ( double time_period ) #

Sets the extrapolation period value for the IG.

Arguments

  • double time_period - Extrapolation period value, in seconds. The default value is 0.04.

double getExtrapolationPeriod ( ) const#

Returns the current extrapolation period value for the IG.

Return value

Extrapolation period value, in seconds. The default value is 0.2.

void setInterpolationLerpFactor ( double factor ) #

Sets the interpolation lerp factor value for the IG. The lower the value the smoother movement will be, but it will feel like objects move underwater or in a jelly, higher values result in higher positioning accuracy (objects positions will be closer to actual ones for the current frame), but objects will move with a noticeable jitter.
Notice
Frame-to-frame interpolation mode must be enabled.

Arguments

  • double factor - Current interpolation lerp factor value, in seconds.

double getInterpolationLerpFactor ( ) const#

Returns the current interpolation lerp factor value for the IG. The lower the value the smoother movement will be, but it will feel like objects move underwater or in a jelly, higher values result in higher positioning accuracy (objects positions will be closer to actual ones for the current frame), but objects will move with a noticeable jitter.
Notice
Frame-to-frame interpolation mode must be enabled.

Return value

Interpolation lerp factor value.

Ptr<ObjectTerrainGlobal> getTerrain ( ) const#

Returns the currently used global terrain object.

Return value

Currently used global terrain object.

Ptr<GeodeticPivot> getGeodeticPivot ( ) const#

Returns the geodetic pivot used to curve the terrain.

Return value

Current geodetic pivot used to curve the terrain.

bool isTerrainCurved ( ) const#

Check if the terrain is curved.

Return value

true, if the terrain is curved, otherwise false.

void setTerrainIntersectionMask ( int mask ) #

Sets the intersection mask that is used to define the ground/landing surface.

Arguments

  • int mask - Intersection mask.

int getTerrainIntersectionMask ( ) const#

Returns the intersection mask that is used to define the ground/landing surface.

Return value

Intersection mask.

bool getHatHot ( const Vec3 & geo_position, double & ret_hat, double & ret_hot, IGIntersection & ret_intersection ) const#

Checks if there is anything in the given geodetic position and returns HAT/HOT as well as surface normal, exact object over which the request was made, intersected surface, world coordinates of the intersection point, etc. to the specified output variables.

Arguments

  • const Vec3 & geo_position - Geodetic position.
  • double & ret_hat - Address for the return HAT value.
  • double & ret_hot - Address for the return HOT value.
  • IGIntersection & ret_intersection - Information on intersection at the given geodetic position, such as exact object over which the request was made, intersected surface, world coordinates of the intersection point, etc.

Return value

true, if there is anything in the given geodetic position, otherwise false.

bool getIntersection ( const Vec3 & p0, const Vec3 & p1, int mask, Unigine::Vector<IGIntersection> & ret ) const#

Checks if the ray with set points intersects with anything.

Arguments

Return value

true, if the ray intersects with anything, otherwise false.

Water * getWater ( ) const#

Returns the interface of the water control.

Return value

Water control interface.

Unigine::Plugins::Syncker::Syncker * getSyncker ( ) const#

Returns the Syncker Interface.

Return value

Pointer to the Syncker::Syncker interface.

Unigine::Plugins::Syncker::Master * getSynckerMaster ( ) const#

Returns the Syncker Master Interface.

Return value

Pointer to the Syncker::Master interface.

Unigine::Plugins::Syncker::Slave * getSynckerSlave ( ) const#

Returns the Syncker Slave Interface.

Return value

Pointer to the Syncker::Slave interface.

Ptr<Node> loadNode ( const char * file_path ) #

Loads a node from the specified file to the world on the Master and all Slaves. This is a network analogue of the loadNode() method of the World class.
Notice
This is a safe analogue of the Syncker method loadNode() that has an internal check if this method runs on the master and if Syncker is running.

Arguments

  • const char * file_path - Path to the *.node file.

Return value

Loaded node or nullptr if an error has occurred.

void syncNode ( const Ptr<Node> & node, unsigned char mask = 255 ) #

Enables synchronization of parameters of the given node via the UDP protocol. Scene nodes are not synchronized by default, this method is used to add a particular node to the synchronization queue.
Notice
This is a safe analogue of the Syncker method addSyncNode() that has an internal check if this method runs on the master and if Syncker is running. If this method is called on a slave, it does nothing.

Arguments

  • const Ptr<Node> & node - Node to synchronize.
  • unsigned char mask - Synchronization mask.

void synckerCreate ( const Ptr<Node> & node, unsigned char mask = 255 ) #

Synchronizes creation of the given node on all Slaves. This method is to be called after node creation on the Master. It is recommended to use the loadNode() method whenever possible as this approach allows adding nodes of all types, unlike the synckerCreate() method that supports only a limited number of them.
Notice
This is a safe analogue of the Syncker method createNode() that has an internal check if this method runs on the master and if Syncker is running. If this method is called on a slave, it does nothing.

Arguments

  • const Ptr<Node> & node - Node to create.
  • unsigned char mask - Synchronization mask.

void synckerDestroy ( const Ptr<Node> & in_node ) #

Synchronizes deletion of the given node (with all its children) on the Master and all Slaves.
Notice
This is a safe analogue of the Syncker method deleteNode() that has an internal check if this method runs on the master and if Syncker is running. If this method is called on a slave, it does nothing.

Arguments

  • const Ptr<Node> & in_node - Node to delete.

bool isSyncNode ( const Ptr<Node> & in_node ) const#

Returns a value indicating if synchronization of the given node is enabled. Using this method you can quickly check if a node is monitored by the Syncker (node's states are dispatched to Slaves over the network).
Notice
This is a safe analogue of the Syncker method isSyncNode() that has an internal check if this method runs on the master and if Syncker is running. If this method is called on a slave, it does nothing.

Arguments

  • const Ptr<Node> & in_node - Node to be checked.

Return value

true if synchronization of the given node is enabled; otherwise, false.

bool checkEntityType ( long long entity_type ) const#

Checks if the given entity type is supported by IG.

Arguments

Return value

true, if the given entity type is supported, otherwise false.

void setCollisionVolumeMask ( int mask ) #

Sets a new collision volume mask for entities.

Arguments

  • int mask - New collision volume mask.

int getCollisionVolumeMask ( ) const#

Returns the current collision volume mask for entities.

Return value

Current collision volume mask for entities.

void setFreeze ( bool value ) #

Sets a value indicating if execution of IG logic is temporarily put on hold (paused). This method can be useful for debugging.

Arguments

  • bool value - true - to put on hold (pause) execution of IG logic; false - to resume execution.

bool isFreeze ( ) const#

Returns a value indicating if execution of IG logic is temporarily put on hold (paused).

Return value

true, if execution of IG logic is temporarily put on hold (paused), otherwise false.

void sendUserMessage ( unsigned char packet_code, const Ptr<Blob> & send_message ) #

Sends user message from the master to a slave.

Arguments

  • unsigned char packet_code - Packet ID.
  • const Ptr<Blob> & send_message - User message

void * addOnUserMessageReceivedCallback ( uint8_t packet_code, Unigine::CallbackBase1 < Unigine::BlobPtr >* callback ) #

Executes the callback function when the user message from the master is received.

Arguments

  • uint8_t packet_code - Packet ID.
  • Unigine::CallbackBase1 < Unigine::BlobPtr >* callback - Callback pointer. The callback function must have the following signature:
    void (Unigine::BlobPtr *blob)

Return value

Callback subscriber ID. This ID can be used to remove this callback when necessary.

void removeOnUserMessageReceivedCallback ( void * subscriber ) #

Removes a callback on receiving a user message for the specified subscriber.

Arguments

  • void * subscriber - Callback subscriber ID specified when adding it.

void clearOnUserMessageReceivedCallbacks ( ) #

Clears all added callbacks on on receiving a user message.

Manager * get ( ) #

Returns the Manager interface.

Return value

Pointer to the manager interface.

bool isMaster ( ) const#

Returns a value indicating if the IG application is a Syncker-Master or runs in a single mode without the Syncker at all.

Return value

true if the IG application is a Syncker-Master or runs in a single mode without the Syncker at all; false if the IG application is a Syncker-Slave.

bool isReady ( ) const#

Returns a value indicating if all Slaves that were waited for by the IG have connected.

Return value

true if all Slaves that were waited for by the IG have connected; otherwise - false.

float getIFps ( ) const#

Returns the inverse FPS value (the time in seconds it took to complete the last frame). This method is similar to the Game::getIFps() but it is more preferred for multi-channel systems as it implements more accurate frame time calculation (including spike-periods).

Return value

Inverse FPS value (1/FPS) - the time in seconds it took to complete the last frame, in seconds.

void setDistanceScale ( float d ) #

Sets the global distance scale for all rendering distance parameters: shadow distance, light distance, LOD distances, etc. (see render_distance_scale console command) and for the IG Simplifier component. The Simplifier component can help optimize rendering of your entities. When assigned to an entity, it enables you to define which parts of its model can be neglected starting at certain distance levels (e.g., hide flaps, ailerons, and rudders at 1km, engines at 5 km, etc.) and which substitutes can be used to represent an entity at a large distance (e.g., a flashing strobe light, when the plane is just a point on the screen).
Notice
This method calls the setDistanceScale() of the Render class.

Arguments

  • float d - Global rendering distance scale and Simplifier component (IG LOD manager).

void setAdaptiveQualitySystemMode ( int mode ) #

Sets a new Adaptive Quality System mode. This system provides automatic real-time adjustment of levels of detail depending on current performance (render_distance_scale and simplifier_distance_scale).

Arguments

  • int mode - Adaptive Quality System mode to be set. One of the following values:
    • 0 - real-time quality adjustment is disabled
    • 1 - degradation mode only (image quality is degraded if the performance goes down)
    • 2 - automatic real-time adjustment (image quality is degraded if the performance is low, and improved if the performance increases)

void destroyObjects ( ) #

Destroys all entities, views, and view groups.

int getCurrentView ( ) const#

Returns the current ID of the view.

Return value

ID of the view.

void setCurrentView ( int view_id ) #

Switches to the view with the specified ID. If the view with the specifie ID does not exist, it will be created automatically.

Arguments

  • int view_id - ID of the view to be set as current.

void setSlaveView ( const char * slave_name, int view_id ) #

Sets a view with the specified ID to be used for the specified Slave (available for Master IG only).

Arguments

  • const char * slave_name - Slave name (-sync_view "").
  • int view_id - ID of the view to be set as current for the specified Slave.

void setSlaveView ( int index, int view_id ) #

Sets a view with the specified ID to be used for a certain Slave by its index (available for Master IG only).

Arguments

  • int index - Slave index in the range from 0 to the total numer of Slaves.
  • int view_id - ID of the view to be set as current for the specified Slave.

int getSlaveView ( const char * slave_name ) const#

Returns the current view ID used for a certain Slave by its name .

Arguments

  • const char * slave_name - Slave name.

Return value

ID of the view used for the Slave with the specified name.

int getSlaveView ( int slave_index ) const#

Returns the current view ID used for a certain Slave by its index (available for Master IG only).

Arguments

Return value

ID of the view used for the Slave with the specified index.

void clearInterpolationData ( ) #

Clears all interpolation data for all entities.

GeodeticsTransformer * getGeodeticsTransformer ( ) const#

Returns a pointer to the instance of the GeodeticsTransformer class if the Geodetics plugin is loaded. This class is used to transform geodetic coordinates (latitude, longitude and altitude) to the 3D world position and vice versa.

Math::dvec3 getGeodeticOrigin ( ) const#

Returns the coordinates of the geodetic origin.

Return value

Geodetic origin coordinates.

int getNumSlaves ( ) const#

Returns the total number of Slaves (available for Master IG only).

Return value

Total number of IG Slaves.

const char * getSlaveName ( int index ) const#

Returns Slave name by its index (available for Master IG only).

Arguments

  • int index - Slave index.

Return value

Name of the Slave with the specified index.

const char * getSynckerName ( ) const#

Returns the current name of the IG host.

Return value

Current name of the IG host.

void setDebugEnabled ( bool v ) #

Console: ig_debug
Sets a value indicating if the Debug mode is enabled. This mode allows inspecting the IG application at run-time.

Arguments

  • bool v - true - to enable the Debug mode; false - to disable it.

bool isDebugEnabled ( ) const#

Console: ig_debug
Returns a value indicating if the Debug mode is enabled. This mode allows inspecting the IG application at run-time

Return value

true if the IG Debug mode is enabled; otherwise, false.

void setDebugMode ( IG::Manager::DEBUG_MODE mode, bool enabled ) #

Sets a value indicating if the specified Debug mode is enabled. This mode allows inspecting the IG application at run-time

Arguments

  • IG::Manager::DEBUG_MODE mode - Debug mode type. One of the DEBUG_MODE_* values.
  • bool enabled - true - to enable the specified Debug mode; false - to disable it.

bool isDebugMode ( IG::Manager::DEBUG_MODE mode ) const#

Returns a value indicating if the specified Debug mode is enabled. This mode allows inspecting the IG application at run-time

Arguments

  • IG::Manager::DEBUG_MODE mode - Debug mode type. One of the DEBUG_MODE_* values.

Return value

true if the specified IG Debug mode is enabled; otherwise, false.

void setDebugDuration ( float time ) #

Console: ig_debug_visualizer_duration
Sets the time period during which Debug visualizer elements are displayed.

Arguments

  • float time - Time interval during which Debug visualizer elements are displayed, in seconds.

float getDebugDuration ( ) const#

Console: ig_debug_visualizer_duration
Returns the current time period during which Debug visualizer elements are displayed.

Return value

Current time interval during which Debug visualizer elements are displayed, in seconds.

void setDebugScreenspace ( bool v ) #

Console: ig_debug_visualizer_screenspace
Sets a value indicating the type of dimensions to be used when rendering Debug visualizer elements.

Arguments

  • bool v - Flag indicating the type of dimensions to be used:
    • false - use the world space dimensions
    • true - use the screen space dimensions

bool isDebugScreenspace ( ) const#

Console: ig_debug_visualizer_screenspace
Returns a value indicating the type of dimensions currently used when rendering Debug visualizer elements.

Return value

Flag indicating the type of dimensions to be used:
  • false - use the world space dimensions
  • true - use the screen space dimensions

void setDebugDepth ( bool v ) #

Console: ig_debug_visualizer_depth
Sets a value indicating if depth testing for the Debug visualizer elements is enabled (if elements should be obscured by the ones closer to the camera).

Arguments

  • bool v - true to enable depth testing for the Debug visualizer elements (if elements should be obscured by the ones closer to the camera); false - to disable it.

bool isDebugDepth ( ) const#

Console: ig_debug_visualizer_depth
Returns a value indicating if depth testing for the Debug visualizer elements is enabled (if elements should be obscured by the ones closer to the camera).

Return value

true if depth testing for the Debug visualizer elements is enabled (if elements should be obscured by the ones closer to the camera); otherwise - false.

void setDebugScale ( float v ) #

Console: ig_debug_visualizer_scale
Sets the new scale multiplier for Debug visualizer elements.

Arguments

  • float v - Scale multiplier for Debug visualizer elements.

float getDebugScale ( ) const#

Console: ig_debug_visualizer_scale
Returns the current scale multiplier for Debug visualizer elements.

Return value

Current scale multiplier for Debug visualizer elements.

float calcDebugScale ( float v ) const#

Returns the actual scale of Debug visualizer elements calculated for the specified value based on the current type of dimensions (world/screen) and the current debug scale value.

Arguments

  • float v - Initial scale value.

Return value

Actual scale of Debug visualizer elements calculated for the specified value. The scale is calculated based on the current debug scale value.

void * addOnCreateViewCallback ( void * subscriber, CallbackBase * callback ) #

Adds a callback function to be executed on creating a new view. The signature of the callback function is as follows:
Source code
void(View *)

Arguments

Return value

ID of the last added Create View callback, if the callback was added successfully; otherwise, nullptr. This ID can be used to remove this callback when necessary.

void removeOnCreateViewCallback ( void * subscriber ) #

Removes a callback function for the specified subscriber from the list of callbacks to be executed on creating a new view.

Arguments

  • void * subscriber - Callback subscriber.

void clearOnCreateViewCallbacks ( ) #

Clears all added Create View callbacks.

void * addOnCreateViewGroupCallback ( void * subscriber, CallbackBase * callback ) #

Adds a callback function to be executed on creating a new view. The signature of the callback function is as follows:
Source code
void(ViewGroup *)

Arguments

void removeOnCreateViewGroupCallback ( void * subscriber ) #

Removes a callback function for the specified subscriber from the list of callbacks to be executed on creating a new view group.

Arguments

  • void * subscriber - Callback subscriber.

void clearOnCreateViewGroupCallbacks ( ) #

Clears all added Create ViewGroup callbacks.

void addOnCreateEntityCallback ( void * subscriber, CallbackBase * callback ) #

Adds a callback function to be executed on creating a new entity. The signature of the callback function is as follows:
Source code
void(IG::ICollisionVolume *volume, Unigine::ContactPtr contact, int contacted_entity, int contacted_volume)

Arguments

void removeOnCreateEntityCallback ( void * subscriber ) #

Removes a callback function for the specified subscriber from the list of callbacks to be executed on creating a new entity.

Arguments

  • void * subscriber - Callback subscriber.

void clearOnCreateEntityCallbacks ( ) #

Clears all added Create Entity callbacks.

void addOnCollisionVolumeDetectedCallback ( void * subscriber, CallbackBase * callback ) #

Adds a callback function to be executed on detecting an intersection with a collision volume. The signature of the callback function is as follows:
Source code
void(IG::ICollisionVolume *volume, Unigine::ContactPtr contact, int contacted_entity, int contacted_volume)

Arguments

void removeOnCollisionVolumeDetectedCallback ( void * subscriber ) #

Removes a callback function for the specified subscriber from the list of callbacks to be executed on detecting an intersection with a collision volume.

Arguments

  • void * subscriber - Callback subscriber.

void clearOnCollisionVolumeDetectedCallbacks ( ) #

Clears all added CollisionVolume Detected callbacks.

void addOnCollisionSegmentDetectedCallback ( void * subscriber, CallbackBase * callback ) #

Adds a callback function to be executed on detecting an intersection with a collision segment. The signature of the callback function is as follows:
Source code
void(IG::ICollisionSegment *segment, Unigine::ObjectPtr object, Unigine::WorldIntersectionPtr intersection)

Arguments

void removeOnCollisionSegmentDetectedCallback ( void * subscriber ) #

Removes a callback function for the specified subscriber from the list of callbacks to be executed on detecting an intersection with a collision segment.

Arguments

  • void * subscriber - Callback subscriber.

void clearOnCollisionSegmentDetectedCallbacks ( ) #

Clears all added CollisionSegment Detected callbacks.

void addOnIGReadyCallback ( void * subscriber, CallbackBase * callback ) #

Adds a callback function to be executed when all Slaves that were waited for by the IG are connected. The signature of the callback function is as follows:
Source code
void()

Arguments

void removeOnIGReadyCallback ( void * subscriber ) #

Removes a callback function for the specified subscriber from the list of callbacks to be executed when all Slaves that were waited for by the IG are connected.

Arguments

  • void * subscriber - Callback subscriber.

void clearOnIGReadyCallbacks ( ) #

Clears all added IG Ready callbacks.

void addOnSlaveConnectedCallback ( void * subscriber, CallbackBase * callback ) #

Adds a callback function to be executed on connecting a new Slave. The signature of the callback function is as follows:
Source code
void(int slave_index, const char * slave_name)

Arguments

void removeOnSlaveConnectedCallback ( void * subscriber ) #

Removes a callback function for the specified subscriber from the list of callbacks to be executed on connecting a new Slave.

Arguments

  • void * subscriber - Callback subscriber.

void clearOnSlaveConnectedCallbacks ( ) #

Clears all added Slave Connected callbacks.

void addOnSlaveDisconnectedCallback ( void * subscriber, CallbackBase * callback ) #

Adds a callback function to be executed on disconnecting a Slave. The signature of the callback function is as follows:
Source code
void(int slave_index)

Arguments

void removeOnSlaveDisconnectedCallback ( void * subscriber ) #

Removes a callback function for the specified subscriber from the list of callbacks to be executed on disconnecting a Slave.

Arguments

  • void * subscriber - Callback subscriber.

void clearOnSlaveDisconnectedCallbacks ( ) #

Clears all added Slave Disconnected callbacks.

void setPropertyWarningEnabled ( bool v ) #

Arguments

  • bool v
Last update: 2022-10-10
Build: ()