# H3DNetworkingUtils::MouseHapticDevice Class Reference

The MouseHapticsDevice class provides an alternative interface to use on haptics programs when a haptic device is not available. More...

`#include <H3DNetworkingUtils/MouseHapticDevice.h>`

List of all members.

## Public Member Functions
| MouseHapticDevice (H3D::Inst< SFMouseSensor > mouseSensor=0)
| Constructor.
virtual void | initialize ()
| Initialize.
## Public Attributes
auto_ptr< SFMouseSensor > | mouseSensor
| The mouseSensor node that is used access type: inputOutput basic type: SFNode default value:.
## Static Public Attributes
static H3D::H3DNodeDatabase | database
| X3D database.

## Detailed Description

The MouseHapticsDevice class provides an alternative interface to use on haptics programs when a haptic device is not available.

It assigns mouse motion to haptic device position. Also assigns the mouse middle button to the haptic main button This is useful to use when there is no haptic device available. It is only active (ie only 'grabs' the proxy) when the mouse left button is pressed. Assignments: mouse right = +ve x mouse left = -ve x mouse up = +ve y mouse down = -ve y mouse up with right button pressed = -ve z (push away) mouse down with right button pressed = +ve z (pull forward) mouse middle button to haptic device main button The node only works if a MouseSensor has been entered into the mouseSensor field. This MouseSensor must be included as a child else where in the scene. Typical (X3D) usage:

       <MouseSensor DEF="mouse"/>
       <DeviceInfo>
          <MouseHapticDevice DEF="HDEV">
             <MouseSensor USE="mouse" containerField="mouseSensor"/>
             <RuspiniRenderer/>
          </MouseHapticDevice>
       </DeviceInfo>

Examples:

- GrabableDynamicTest.x3d

The documentation for this class was generated from the following files:

- MouseHapticDevice.h
- MouseHapticDevice.cpp