Xj3D VRML/X3D Code API

org.web3d.vrml.device
Class TrackerState

java.lang.Object
  extended byorg.web3d.vrml.device.DeviceState
      extended byorg.web3d.vrml.device.TrackerState

public class TrackerState
extends DeviceState

Holds a single tracker's state.

A sensor is responsible for converting its coordinates into worldCoordinates Needs to return position, orientation and button state action(Picking, Navigation, Orientation)

Version:
$Revision: 1.5 $
Author:
Alan Hudson

Field Summary
 int actionMask
          A mask of actions this tracker might return.
 int actionType
          What action is this state record for
 int[] buttonMode
          What navigation mode should this button use
 boolean[] buttonState
           
 float[] deviceOri
          An orientation vector in device coords
 float[] devicePos
          The position of the tracker in device coordinates
 int numButtons
          The number of buttons the tracker has
 boolean[] pickingEnabled
          Is picking enabled for this button
static int TYPE_BUTTON
          Only a button changed state, nothing else
static int TYPE_CLICK
          The action type was a click
static int TYPE_DRAG
          The action type was a drag
static int TYPE_MOVE
          The action type was a movement
static int TYPE_NONE
          No type event was processed
static int TYPE_ORIENTATION
          The action type was a orientation change
static int TYPE_PRESS
          The action type was a press
static int TYPE_RELEASE
          The action type was a release
 float[] worldOri
          The orientation in world coordinates
 float[] worldPos
          The position in world coordinates.
 
Constructor Summary
TrackerState()
          Create a new default state.
 
Methods inherited from class org.web3d.vrml.device.DeviceState
clearChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TYPE_NONE

public static final int TYPE_NONE
No type event was processed

See Also:
Constant Field Values

TYPE_PRESS

public static final int TYPE_PRESS
The action type was a press

See Also:
Constant Field Values

TYPE_DRAG

public static final int TYPE_DRAG
The action type was a drag

See Also:
Constant Field Values

TYPE_CLICK

public static final int TYPE_CLICK
The action type was a click

See Also:
Constant Field Values

TYPE_RELEASE

public static final int TYPE_RELEASE
The action type was a release

See Also:
Constant Field Values

TYPE_MOVE

public static final int TYPE_MOVE
The action type was a movement

See Also:
Constant Field Values

TYPE_ORIENTATION

public static final int TYPE_ORIENTATION
The action type was a orientation change

See Also:
Constant Field Values

TYPE_BUTTON

public static final int TYPE_BUTTON
Only a button changed state, nothing else

See Also:
Constant Field Values

actionMask

public int actionMask
A mask of actions this tracker might return. Defined in Tracker


actionType

public int actionType
What action is this state record for


devicePos

public float[] devicePos
The position of the tracker in device coordinates


deviceOri

public float[] deviceOri
An orientation vector in device coords


worldPos

public float[] worldPos
The position in world coordinates.


worldOri

public float[] worldOri
The orientation in world coordinates


buttonState

public boolean[] buttonState

pickingEnabled

public boolean[] pickingEnabled
Is picking enabled for this button


buttonMode

public int[] buttonMode
What navigation mode should this button use


numButtons

public int numButtons
The number of buttons the tracker has

Constructor Detail

TrackerState

public TrackerState()
Create a new default state. The type is set to NONE and all items are initialised to zero arrays.


Xj3D VRML/X3D Code API

Copyright © 2001 - 2005 Web3D Consortium