|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.sun.j3d.utils.behaviors.sensor.SensorInputAdaptor
com.sun.j3d.utils.behaviors.vp.WandViewBehavior.ListenerBase
public class WandViewBehavior.ListenerBase
A base class for implementing some of this behavior's listeners.
| Field Summary | |
|---|---|
protected Transform3D |
sensorToTracker
The initial transform from sensor coordinates to tracker base coordinates, set by initAction. |
protected Transform3D |
sensorToVworld
The initial transform from sensor coordinates to virtual world coordinates, set by initAction. |
protected Transform3D |
trackerToVworld
The initial transform from tracker base coordinates to virtual world coordinates, set by initAction. |
protected Transform3D |
viewPlatformToVworld
The initial transform from view platform coordinates to virtual world coordinates, set by initAction. |
| Constructor Summary | |
|---|---|
WandViewBehavior.ListenerBase()
|
|
| Method Summary | |
|---|---|
protected void |
conditionViewScale(Transform3D viewPlatformToVworld)
Equalizes the scale factors in the view tranform, which must be congruent. |
protected void |
endAction(Sensor s)
Ends the action. |
protected double |
getPhysicalToViewPlatformScale()
Gets the scale from physical units to view platform units. |
protected double |
getPhysicalToVirtualScale()
Gets the physical to virtual scale. |
protected void |
initAction(Sensor s)
Initializes the listener action. |
protected boolean |
isActive()
Returns true if the listener is currently active; that is, if initAction has been called but not yet
endAction. |
void |
pressed(SensorEvent e)
This method is called when a sensor's button is pressed. |
void |
released(SensorEvent e)
This method is called when a sensor's button is released. |
protected void |
transformAboutCenter(Transform3D target,
Point3d center,
Transform3D transform)
Transforms the target coordinate system about a center point. |
protected void |
translateTransform(Transform3D transform,
Vector3d translation)
Translates a coordinate system. |
| Methods inherited from class com.sun.j3d.utils.behaviors.sensor.SensorInputAdaptor |
|---|
clicked, dragged, read |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Transform3D viewPlatformToVworld
initAction.
protected Transform3D trackerToVworld
initAction.
protected Transform3D sensorToVworld
initAction.
protected Transform3D sensorToTracker
initAction.
| Constructor Detail |
|---|
public WandViewBehavior.ListenerBase()
| Method Detail |
|---|
protected void initAction(Sensor s)
pressed or when a 2D
valuator exits the deadzone threshold.
s - reference to a 6DOF sensor if used by the listener; may
be nullprotected void endAction(Sensor s)
released or when a 2D valuator enters the deadzone
threshold.
s - reference to a 6DOF sensor if used by the listener; may
be nullprotected boolean isActive()
initAction has been called but not yet
endAction.
public void pressed(SensorEvent e)
SensorButtonListener
pressed in interface SensorButtonListenerpressed in class SensorInputAdaptore - the sensor eventpublic void released(SensorEvent e)
SensorButtonListener
released in interface SensorButtonListenerreleased in class SensorInputAdaptore - the sensor eventprotected double getPhysicalToVirtualScale()
protected double getPhysicalToViewPlatformScale()
protected void translateTransform(Transform3D transform,
Vector3d translation)
transform - the coordinate system to be translatedtranslation - the vector by which to translate
protected void transformAboutCenter(Transform3D target,
Point3d center,
Transform3D transform)
target - the coordinate system to transformcenter - the center point about which to transformtransform - the transform to applyprotected void conditionViewScale(Transform3D viewPlatformToVworld)
ViewingPlatform
TransformGroup is updated; otherwise, its transform is reset
to the home transform. This should be called if multiple
incremental scale factors are applied to the view transform.
viewPlatformToVworld - the view transform
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||