Public Member Functions | |
| HRESULT | InitPhysEngine (void) |
| HRESULT | StartSimulation (void) |
| HRESULT | StopSimulation ([in] RtBool *bContinue) |
| HRESULT | GetActiveState ([out] RtBool *bActive) |
| HRESULT | RegisterObj ([in] IRsBaseNode *pNode) |
| HRESULT | UnRegisterObj ([in] IRsBaseNode *pNode) |
| HRESULT | PickPhysObj ([in] RtPoint *pScreenPoint,[in] IRsNode *pView,[out] IRsNode **pSelNode) |
| HRESULT | SetMouseMove ([in] RtPoint *pScreenPoint,[in] IRsNode *pView,[in] RtShort *flags) |
| HRESULT | FreePickedObj (void) |
| HRESULT | AddImpulse ([in] IRsNode *pNode,[in] RtPoint force,[in] RtPoint torque) |
| HRESULT | EnumObjects ([in] RtFloat *box,[in] RtBool bSubObj,[out] IRsList **ppList) |
| HRESULT | BlockNetworkSync ([in] RtBool bBlock) |
| HRESULT | ActivateObj ([in] IRsBaseNode *pNode,[in] RtBool bActivate) |
| HRESULT | NetworkStatus ([out] RtUshort *uStatus) |
| HRESULT IRnPhysEngine::InitPhysEngine | ( | void | ) |
Initialize phys engine object and all objects included in simulation.
| HRESULT IRnPhysEngine::StartSimulation | ( | void | ) |
Start simulation managed by internal timer, there is no need to call InitPhysEngine method if engine is started using this method.
| HRESULT IRnPhysEngine::StopSimulation | ( | [in] RtBool * | bContinue | ) |
StopSimulation - stops simulation managed by internal timer. All internal data structure is freed.
| bContinue | [in] If FALSE, objects are returned back to their original positions, if TRUE objects remain in their last position. |
| HRESULT IRnPhysEngine::GetActiveState | ( | [out] RtBool * | bActive | ) |
Return the status of engine object.
| bActive | [out] If TRUE engine is running, if FALSE engine is inactive. |
| HRESULT IRnPhysEngine::RegisterObj | ( | [in] IRsBaseNode * | pNode | ) |
RegisterObj - adds object to running simulation, if object is animated, animation is switched to simulation for that object.
| pNode | [in] Object to add. |
| HRESULT IRnPhysEngine::UnRegisterObj | ( | [in] IRsBaseNode * | pNode | ) |
Remove object to running simulation, if object is animated, simulation is switched to animation for that object.
| pNode | [in] Object to remove. |
| HRESULT IRnPhysEngine::PickPhysObj | ( | [in] RtPoint * | pScreenPoint, | |
| [in] IRsNode * | pView, | |||
| [out] IRsNode ** | pSelNode | |||
| ) |
Pick and select object in running simulation for next manipulation with mouse.
| pScreenPoint | [in] Screen point. | |
| pView | View node. | |
| pSelNode | - v Picked object, if NULL no object is picked. |
| HRESULT IRnPhysEngine::SetMouseMove | ( | [in] RtPoint * | pScreenPoint, | |
| [in] IRsNode * | pView, | |||
| [in] RtShort * | flags | |||
| ) |
Set mouse movement to object in running simulation according mouse movement.
| pScreenPoint | [in] Screen point. | |
| pView | [in] View node. | |
| flags | [in] Parameters of translation process. |
| HRESULT IRnPhysEngine::FreePickedObj | ( | void | ) |
Free picked object (returned from previous call to PickPhysObj method).
Add impulse to object in running simulation.
| pNode | [in] Pointer to object. | |
| force | [in] Impulse force (acceleration). | |
| torque | [in] Torque force (angular acceleration). |
| HRESULT IRnPhysEngine::EnumObjects | ( | [in] RtFloat * | box, | |
| [in] RtBool | bSubObj, | |||
| [out] IRsList ** | ppList | |||
| ) |
Enumerate all objects in given box.
| box | [in] Float array of box {xmin, xmax, ymin, ymax, zmin, zmax}. | |
| bSubObj | [in] If TRUE all objects and their sub objects are included, if FALSE only phys objects are listed. | |
| ppList | [in] List of objects. |
| HRESULT IRnPhysEngine::BlockNetworkSync | ( | [in] RtBool | bBlock | ) |
Block all network communication.
| bBlock | [in] If TRUE network communication is blocked, if FALSE is unblocked. |
| HRESULT IRnPhysEngine::ActivateObj | ( | [in] IRsBaseNode * | pNode, | |
| [in] RtBool | bActivate | |||
| ) |
Activate/Deactivate physics for object in running simulation, if object is deactivated, simulation is switched to animation for that object.
| pNode | [in] Object to activate/deactivate. | |
| bActivate | [in] If TRUE object is activate, if FALSE object is deactivated. |
| HRESULT IRnPhysEngine::NetworkStatus | ( | [out] RtUshort * | uStatus | ) |
Get engine's network status.
| uStatus | [out] Engine's network status: 0 - local mode, 1 - server master, 2 - server slave |
1.5.5