#include <HLHapticsDevice.h>
Inheritance diagram for H3D::HLHapticsDevice:

Public Types | |
| typedef TypedSFNode< DeviceLog > | SFDeviceLog |
Public Member Functions | |
| H3D_VALUE_EXCEPTION (string, CouldNotInitHapticsDevice) | |
| HLHapticsDevice (Inst< SFVec3f > _devicePosition=0, Inst< SFRotation > _deviceOrientation=0, Inst< TrackerPosition > _trackerPosition=0, Inst< TrackerOrientation > _trackerOrientation=0, Inst< PosCalibration > _positionCalibration=0, Inst< OrnCalibration > _orientationCalibration=0, Inst< SFVec3f > _proxyPosition=0, Inst< WeightedProxy > _weightedProxyPosition=0, Inst< SFFloat > _proxyWeighting=0, Inst< SFBool > _mainButton=0, Inst< SFVec3f > _force=0, Inst< SFVec3f > _torque=0, Inst< SFInt32 > _inputDOF=0, Inst< SFInt32 > _outputDOF=0, Inst< SFInt32 > _hapticsRate=0, Inst< SFNode > _stylus=0, Inst< SFBool > _initialized=0, Inst< SFString > _deviceName=0, Inst< SFBool > _secondaryButton=0, Inst< SFDeviceLog > _deviceLog=0) | |
| Construtor. | |
| virtual | ~HLHapticsDevice () |
| Destructor. | |
| virtual void | preRender () |
| Starts a new haptic frame. | |
| virtual void | postRender () |
| Ends the haptic frame. | |
| virtual void | initDevice () |
| Does all the initialization needed for the device before starting to use it. | |
| virtual void | initHLLayer () |
| virtual void | resetDevice () |
| Reset the device. | |
| virtual void | disableDevice () |
| Perform cleanup and let go of all device resources that are allocated. | |
| virtual void | updateDeviceValues () |
| This function is used to transfer device values, such as position, button status etc from the realtime loop to the fields of HLHapticsDevice, and possible vice versa. | |
| virtual void | renderShapes (const HapticShapeVector &shapes) |
| Uses the HLAPI to render the objects. | |
| virtual void | renderEffects (const HapticEffectVector &effects) |
| Uses HLAPI to render the ForceEffects. | |
| HapticEffectVector & | getCurrentForceEffects () |
| Returns the force effects to render in the realtime loop. | |
| HapticEffectVector & | getLastForceEffects () |
| Returns the force effects that was rendered during last scene graph loop. | |
| HHD | getDeviceHandle () |
| Returns the HD device handle for this device. | |
| HHLRC | getHapticContext () |
| Returns the haptic context for this device. | |
Static Public Member Functions | |
| static void HLCALLBACK | hlButtonCallback (HLenum event, HLuint object, HLenum thread, HLcache *cache, void *data) |
Public Attributes | |
| auto_ptr< SFString > | deviceName |
| The name of the device. | |
| auto_ptr< SFBool > | secondaryButton |
| The status of the secondary button (if such a button exists). | |
| auto_ptr< SFDeviceLog > | deviceLog |
| Logging Node that can be used to log device position and orientation information to a binary file. | |
| TimeStamp | last_effect_change |
| The time for the last call to the changeForceEffects callback function. | |
| TimeStamp | last_loop_time |
| The time between the previous two calls to changeForceEffects. | |
| AutoRef< DeviceLog > | log |
| Realtime pointer to deviceLog. | |
Static Public Attributes | |
| static H3DNodeDatabase | database |
| The H3DNodeDatabase for this node. | |
Protected Attributes | |
| HHD | device_handle |
| The device handle used in the HLAPI. | |
| HHLRC | haptic_context |
| The HLAPI haptic context used by this device. | |
| vector< HDCallbackCode > | hd_handles |
| Handle for the callback for rendering ForceEffects. | |
|
|
Perform cleanup and let go of all device resources that are allocated. After a call to this function no haptic rendering can be performed on the device until the initDevice() function has been called again. Reimplemented from H3D::H3DHapticsDevice. |
|
|
Returns the force effects to render in the realtime loop. Should not be called from the scenegraph loop. |
|
|
Returns the haptic context for this device. Before rendering anything on this device this context must have been made active |
|
|
Returns the force effects that was rendered during last scene graph loop. Should not be called from the scenegraph loop. |
|
|
Uses HLAPI to render the ForceEffects.
|
|
|
Uses the HLAPI to render the objects. The objects given must be a subclass to HLObject in order to be rendered. |
|
|
Logging Node that can be used to log device position and orientation information to a binary file.
Access type: initializeOnly
|
|
|
The name of the device.
Access type: initializeOnly
|
|
|
The status of the secondary button (if such a button exists). true means that the button is pressed
Access type: outputOnly
|
1.4.5