This page has been translated automatically.
视频教程
界面
要领
高级
实用建议
专业(SIM)
UnigineEditor
界面概述
资源工作流程
版本控制
设置和首选项
项目开发
调整节点参数
Setting Up Materials
设置属性
照明
Sandworm
使用编辑器工具执行特定任务
如何擴展編輯器功能
嵌入式节点类型
Nodes
Objects
Effects
Decals
光源
Geodetics
World Nodes
Sound Objects
Pathfinding Objects
Players
编程
基本原理
搭建开发环境
使用范例
C++
C#
UnigineScript
UUSL (Unified UNIGINE Shader Language)
Plugins
File Formats
材质和着色器
Rebuilding the Engine Tools
GUI
VR Development
双精度坐标
应用程序接口
Animations-Related Classes
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
VR-Related Classes
创建内容
内容优化
材质
Material Nodes Library
Miscellaneous
Input
Math
Matrix
Textures
Art Samples
Tutorials
注意! 这个版本的文档是过时的,因为它描述了一个较老的SDK版本!请切换到最新SDK版本的文档。
注意! 这个版本的文档描述了一个不再受支持的旧SDK版本!请升级到最新的SDK版本。

IG::DIS::Connector 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/Unigine/DISConnector/UnigineDISConnector.h>

IG::DIS::Connector Class

Members


void init ( String ip, int site, int exercise, int app, int port ) #

Initializes the DIS Connector using the given parameters.

Arguments

  • String ip - Broadcast address of the server computer that is used to broadcast messages to IG over the network
  • int site - Site ID of this application instance.
  • int exercise - Exercise ID of the DIS.
  • int app - Application ID of this application instance. If not set, will be generated automatically.
  • int port - Connection port. This argument is optional, default value is 3000.

void * addConnectCallback ( Unigine::CallbackBase * func ) #

Sets the parameter to be called when connection is established.

Arguments

  • Unigine::CallbackBase * func - Parameter to be called when connection is established.

Return value

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

bool removeConnectCallback ( void * id ) #

Removes the specified callback from the list of Connect callbacks.

Arguments

  • void * id - Connect callback ID obtained when adding it.

Return value

True if the Connect callback with the given ID was removed successfully; otherwise false.

void * addReceivePacketCallback ( int pdu_type, Unigine::CallbackBase * func ) #

Adds a callback function to be fired when the packet is received.

Arguments

  • int pdu_type - PDU type.
  • Unigine::CallbackBase * func - Callback function to be called when the packet is received. Callback signature: void func(KDIS::PDU::Header *packet).

Return value

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

bool removeReceivePacketCallback ( void * id ) #

Removes the specified callback from the list of Receive Packet callbacks.

Arguments

  • void * id - Receive Packet callback ID obtained when adding it.

Return value

True if the Receive Packet callback with the given ID was removed successfully; otherwise false.

int64_t getInternalEntityID ( int app, int id ) #

Returns the IG internal entity ID.

Arguments

  • int app - Application ID.
  • int id - DIS entity ID.

Return value

IG internal entity ID.

void setProcessPacket ( int op_code, bool enabled ) #

Sets a value indicating if the specified IG packets received are to be processed or skipped.

Arguments

  • int op_code - PDU type identifier.
  • bool enabled - true to process packets of the specified type, false to skip them.

void setConnectionThreadCallbacks ( Unigine::CallbackBase * on_connect, Unigine::CallbackBase * on_disconnect ) #

Sets callbacks for tuning the connection instance.
Warning
This callback will be invoked in a thread that is not the main thread.

Arguments

  • Unigine::CallbackBase * on_connect - Parameter to be called in the connection thread immediately after the connection is established. Callback's signature: void func(KDIS::NETWORK::Connection * connection).
  • Unigine::CallbackBase * on_disconnect - Parameter to be called after a connection failure or shutdown. Callback's signature: void func(KDIS::NETWORK::Connection * connection).
    Notice
    Connection may be nullptr.

void setDeadReckoningStatic ( Unigine::Plugins::IG::Entity * entity ) #

Sets the Static dead reckoning algorithm to be used for the specified entity (Entity does not move).
Dead Reckoning algorithms (Static, FPW, RPW, RVW, FVW, FPB, RPB, RVB, FVB) are used in Advanced Distributed Simulation to reduce the need to continually update a simulated entity's state information by the estimation of the position and orientation of an entity, based on a previously known position and orientation and estimates of the passage of simulation time and motion.

Arguments

  • Unigine::Plugins::IG::Entity * entity - Simulated Entity, for which the Static dead reckoning algorithm is to be used.

void setDeadReckoningFPW ( Unigine::Plugins::IG::Entity * entity, const Vec3 & linear_velocity ) #

Sets the FPW dead reckoning algorithm to be used for the specified entity along with the specified constant rates. FPW means: F - fixed rotation, P - rate of position is to be held constant (velocity), B - world coordinate system.
Dead Reckoning algorithms (Static, FPW, RPW, RVW, FVW, FPB, RPB, RVB, FVB) are used in Advanced Distributed Simulation to reduce the need to continually update a simulated entity's state information by the estimation of the position and orientation of an entity, based on a previously known position and orientation and estimates of the passage of simulation time and motion.

Arguments

  • Unigine::Plugins::IG::Entity * entity - Simulated Entity, for which the FPW dead reckoning algorithm is to be used with the specified values.
  • const Vec3 & linear_velocity - Linear velocity vector.

void setDeadReckoningRPW ( Unigine::Plugins::IG::Entity * entity, const Vec3 & linear_velocity, const vec3 & angular_velocity_deg ) #

Sets the RPW dead reckoning algorithm to be used for the specified entity along with the specified constant rates. RPW means: R - rotating, P - rate of position is to be held constant (velocity), B - world coordinate system.
Dead Reckoning algorithms (Static, FPW, RPW, RVW, FVW, FPB, RPB, RVB, FVB) are used in Advanced Distributed Simulation to reduce the need to continually update a simulated entity's state information by the estimation of the position and orientation of an entity, based on a previously known position and orientation and estimates of the passage of simulation time and motion.

Arguments

  • Unigine::Plugins::IG::Entity * entity - Simulated Entity, for which the RPW dead reckoning algorithm is to be used with the specified values.
  • const Vec3 & linear_velocity - Linear velocity vector.
  • const vec3 & angular_velocity_deg - Vector containing angular velocity values for each of the axes, in degrees.

void setDeadReckoningRVW ( Unigine::Plugins::IG::Entity * entity, const Vec3 & linear_velocity, const Vec3 & linear_acceleration, const vec3 & angular_velocity_deg ) #

Sets the RVW dead reckoning algorithm to be used for the specified entity along with the specified constant rates. RVW means: R - rotating, V - rate of velocity is to be held constant (velocity + acceleration), W - world coordinate system.
Dead Reckoning algorithms (Static, FPW, RPW, RVW, FVW, FPB, RPB, RVB, FVB) are used in Advanced Distributed Simulation to reduce the need to continually update a simulated entity's state information by the estimation of the position and orientation of an entity, based on a previously known position and orientation and estimates of the passage of simulation time and motion.

Arguments

  • Unigine::Plugins::IG::Entity * entity - Simulated Entity, for which the RVW dead reckoning algorithm is to be used with the specified values.
  • const Vec3 & linear_velocity - Linear velocity vector.
  • const Vec3 & linear_acceleration - Linear acceleration vector.
  • const vec3 & angular_velocity_deg - Vector containing angular velocity values for each of the axes, in degrees.

void setDeadReckoningFVW ( Unigine::Plugins::IG::Entity * entity, const Vec3 & linear_velocity, const Vec3 & linear_acceleration ) #

Sets the FVW dead reckoning algorithm to be used for the specified entity along with the specified constant rates. FVW means: F - fixed rotation, V - rate of velocity is to be held constant (velocity + acceleration), W - world coordinate system.
Dead Reckoning algorithms (Static, FPW, RPW, RVW, FVW, FPB, RPB, RVB, FVB) are used in Advanced Distributed Simulation to reduce the need to continually update a simulated entity's state information by the estimation of the position and orientation of an entity, based on a previously known position and orientation and estimates of the passage of simulation time and motion.

Arguments

  • Unigine::Plugins::IG::Entity * entity - Simulated Entity, for which the FVW dead reckoning algorithm is to be used with the specified values.
  • const Vec3 & linear_velocity - Linear velocity vector.
  • const Vec3 & linear_acceleration - Linear acceleration vector.

void setDeadReckoningFPB ( Unigine::Plugins::IG::Entity * entity, const Vec3 & linear_velocity, const vec3 & angular_velocity_deg ) #

Sets the FPB dead reckoning algorithm to be used for the specified entity along with the specified constant rates. FPB means: F - fixed rotation, P - rate of position is to be held constant (velocity), B - body-centered coordinate system.
Dead Reckoning algorithms (Static, FPW, RPW, RVW, FVW, FPB, RPB, RVB, FVB) are used in Advanced Distributed Simulation to reduce the need to continually update a simulated entity's state information by the estimation of the position and orientation of an entity, based on a previously known position and orientation and estimates of the passage of simulation time and motion.

Arguments

  • Unigine::Plugins::IG::Entity * entity - Simulated Entity, for which the FPB dead reckoning algorithm is to be used with the specified values.
  • const Vec3 & linear_velocity - Linear velocity vector.
  • const vec3 & angular_velocity_deg - Vector containing angular velocity values for each of the axes, in degrees.

void setDeadReckoningRPB ( Unigine::Plugins::IG::Entity * entity, const Vec3 & linear_velocity, const vec3 & angular_velocity_deg ) #

Sets the RPB dead reckoning algorithm to be used for the specified entity along with the specified constant rates. RPB means: R - rotating, P - rate of position is to be held constant (velocity), B - body-centered coordinate system.
Dead Reckoning algorithms (Static, FPW, RPW, RVW, FVW, FPB, RPB, RVB, FVB) are used in Advanced Distributed Simulation to reduce the need to continually update a simulated entity's state information by the estimation of the position and orientation of an entity, based on a previously known position and orientation and estimates of the passage of simulation time and motion.

Arguments

  • Unigine::Plugins::IG::Entity * entity - Simulated Entity, for which the RPB dead reckoning algorithm is to be used with the specified values.
  • const Vec3 & linear_velocity - Linear velocity vector.
  • const vec3 & angular_velocity_deg - Vector containing angular velocity values for each of the axes, in degrees.

void setDeadReckoningRVB ( Unigine::Plugins::IG::Entity * entity, const Vec3 & linear_velocity, const Vec3 & linear_acceleration, const vec3 & angular_velocity_deg ) #

Sets the RVB dead reckoning algorithm to be used for the specified entity along with the specified constant rates. RVB means: R - rotating, V - rate of velocity is to be held constant (velocity + acceleration), B - body-centered coordinate system.
Dead Reckoning algorithms (Static, FPW, RPW, RVW, FVW, FPB, RPB, RVB, FVB) are used in Advanced Distributed Simulation to reduce the need to continually update a simulated entity's state information by the estimation of the position and orientation of an entity, based on a previously known position and orientation and estimates of the passage of simulation time and motion.

Arguments

  • Unigine::Plugins::IG::Entity * entity - Simulated Entity, for which the RVB dead reckoning algorithm is to be used with the specified values.
  • const Vec3 & linear_velocity - Linear velocity vector.
  • const Vec3 & linear_acceleration - Linear acceleration vector.
  • const vec3 & angular_velocity_deg - Vector containing angular velocity values for each of the axes, in degrees.

void setDeadReckoningFVB ( Unigine::Plugins::IG::Entity * entity, const Vec3 & linear_velocity, const Vec3 & linear_acceleration, const vec3 & angular_velocity_deg ) #

Sets the FVB dead reckoning algorithm to be used for the specified entity along with the specified constant rates. FVB means: F - fixed rotation, V - rate of velocity is to be held constant (velocity + acceleration), B - body-centered coordinate system.
Dead Reckoning algorithms (Static, FPW, RPW, RVW, FVW, FPB, RPB, RVB, FVB) are used in Advanced Distributed Simulation to reduce the need to continually update a simulated entity's state information by the estimation of the position and orientation of an entity, based on a previously known position and orientation and estimates of the passage of simulation time and motion.

Arguments

  • Unigine::Plugins::IG::Entity * entity - Simulated Entity, for which the FVB dead reckoning algorithm is to be used with the specified values.
  • const Vec3 & linear_velocity - Linear velocity vector.
  • const Vec3 & linear_acceleration - Linear acceleration vector.
  • const vec3 & angular_velocity_deg - Vector containing angular velocity values for each of the axes, in degrees.
Last update: 2023-12-19
Build: ()