IG::ManagerInterface Class
Header: | #include <IGInterface.h> |
ManagerInterface Class
Members
const char * getConfigPath( )
Returns the pathe to the IG configuration file (ig_config.xml).Return value
Path to the IG configuration file (ig_config.xml).bool loadDatabase( int db )
Loads the database with the specified ID and sets it to be used.Arguments
- int db - ID of the database to be used.
Return value
true the database with the specified ID is loaded successfully; otherwise, false.int getDatabaseID( )
Returns the ID of the database currently used.Return value
ID of the database currently used.bool isDatabaseLoaded( )
Returns a value indicating if any database is currently loaded.Return value
true if any database is currently loaded; otherwise, false.ISkyMap * getSkyMap( )
Returns the interface of the sky map.Return value
Sky map interface.IMeteo * getMeteo( )
Returns the meteo interface.Return value
Meteo interface.void setCoordinateSystem( int coord_system )
Sets the specified coordinate system to be used.Arguments
- int coord_system - Coordinate system to be set. One of the COORDINATE_SYSTEM::* values.
int getCoordinateSystem( )
Returns the currently used coordinate system.Return value
Coordinate system currently used.IConverter * getConverter( )
Returns the converter interface.Return value
Converter interface.IView * getView( int view_id )
Returns the interface of the specified view.The specified view will be created, if it doesn't exist yet.
Arguments
- int view_id - ID of the view.
Return value
Pointer to the view interface.IViewGroup * getViewGroup( int group_id )
Returns the interface of the specified view group.The specified view group will be created, if it doesn't exist yet.
Arguments
- int group_id - ID of the view group.
Return value
Pointer to the view group interface.IEntity * getEntity( int entity_id )
Returns the interface of the specified entity.The specified entity will be created, if it doesn't exist yet.
Arguments
- int entity_id - ID of the entity.
Return value
Pointer to the entity interface.int isEntity( int entity_id )
Returns a value indicating if an entity with the specified ID exists.Arguments
- int entity_id - ID of the entity.
Return value
1 if an entity with the specified ID exists; otherwise, 0.IEntity * findEntity( const Unigine::NodePtr & node )
Returns the interface of the entity represented by the specified node.Arguments
- const Unigine::NodePtr & node - Node for which an entity is to be found.
Return value
Pointer to the entity interface.int findEntityType( const char * type_name )
Returns the entity type ID by its name.Entity type IDs are defined in the entity definition section of the IG configuration file.
Arguments
- const char * type_name - Entity type name.
Return value
Entity type ID.int findComponentID( int entity_type, const char * name )
Returns the ID of the component with the given name, which belongs to the specified entity type.Arguments
- int entity_type - Entity type ID.Entity type IDs are defined in the entity definition section of the IG configuration file.
- const char * name - Component name.
Return value
Component ID.void setPlayer( int view_id )
Sets the view with the given ID as a current one.Arguments
- int view_id - ID of the view to be set.
void setInterpolation( int enabled )
Sets a value indicating if interpolation and extrapolation should be enabled for the IG.Arguments
- int enabled - 1 to enable interpolation and extrapolation for the IG; 0 - to disable.
int isInterpolation( )
Returns a value indicating if interpolation and extrapolation are enabled for the IG.Return value
1 if interpolation and extrapolation are enabled for the IG; otherwise, 0.void setInterpolationLerp( int enabled )
Sets a value indicating if interpolation between the current and previous frames should be enabled for the IG.Arguments
- int enabled - 1 to enable interpolation between the current and previous frames for the IG; 0 - to disable.
int isInterpolationLerp( )
Returns a value indicating if interpolation between the current and previous frames is enabled for the IG.Return value
1 if interpolation between the current and previous frames is enabled for the IG; otherwise, 0.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( )
Returns the current interpolation time value for the IG.Return value
Interpolation time value, in seconds.void setInterpolationPeriod( double period )
Sets the interpolation period value for the IG.Arguments
- double period - Interpolation period value, in seconds. The default value is 0.04.
double getInterpolationPeriod( )
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 period )
Sets the extrapolation period value for the IG.Arguments
- double period - Extrapolation period value, in seconds. The default value is 0.04.
int getExtrapolationPeriod( )
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 current_time )
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.Frame-to-frame interpolation mode must be enabled.
Arguments
- double current_time - Current interpolation lerp factor value, in seconds.
double getInterpolationLerpFactor( )
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.Frame-to-frame interpolation mode must be enabled.
Return value
Interpolation lerp factor value.const Unigine::ObjectTerrainGlobalPtr & getTerrain( )
Returns the currently used terrain object.Return value
Currently used terrain object.const Unigine::GeodeticPivotPtr & getGeodeticPivot( )
Returns the geodetic pivot used to curve the terrain.Return value
Current geodetic pivot used to curve the terrain.Unigine::Syncker::MasterInterface * getSynckerMaster( )
Returns the Syncker Master Interface.Return value
Pointer to the Syncker::MasterInterface interface.Last update:
14.02.2019
Помогите сделать статью лучше
Была ли эта статья полезной?
(или выберите слово/фразу и нажмите Ctrl+Enter