|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.ObjectBehavior
com.sun.electric.plugins.j3d.J3DKeyBehavior
public class J3DKeyBehavior
Inspired in example found in Daniel Selman's book "Java 3D Programming" For more information about the original example, contact Daniel Selman: daniel@selman.org Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
| Field Summary | |
|---|---|
protected static double |
FAST_SPEED
|
protected WakeupCondition |
keyCriterion
|
protected static double |
NORMAL_SPEED
|
protected TransformGroup |
tGroup
|
protected Transform3D |
transform
|
| Constructor Summary | |
|---|---|
J3DKeyBehavior(TransformGroup tg)
|
|
| Method Summary | |
|---|---|
protected void |
altMove(int keycode)
|
protected void |
controlMove(int keycode)
|
protected double |
getMovementRate()
|
void |
initialize()
|
void |
moveAlongAxis(int axis,
int dir)
Method to shift along axis in direction provided |
protected void |
processKeyEvent(java.awt.event.KeyEvent event)
|
void |
processStimulus(java.util.Enumeration criteria)
|
protected boolean |
rotate(int axis,
double radians,
boolean force)
Method that rotates along given axis |
protected void |
rotateAlongAxis(int axis,
int dir)
Method to rotate along given axis and direction provided |
void |
setHomeRotation(double[] rotVals)
Method to set the original rotation |
protected boolean |
updateTransform(boolean force)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final double FAST_SPEED
protected static final double NORMAL_SPEED
protected TransformGroup tGroup
protected Transform3D transform
protected WakeupCondition keyCriterion
| Constructor Detail |
|---|
public J3DKeyBehavior(TransformGroup tg)
| Method Detail |
|---|
public void initialize()
public void processStimulus(java.util.Enumeration criteria)
protected void processKeyEvent(java.awt.event.KeyEvent event)
protected void altMove(int keycode)
protected void controlMove(int keycode)
public void moveAlongAxis(int axis,
int dir)
axis - dir -
protected void rotateAlongAxis(int axis,
int dir)
axis - dir - protected boolean updateTransform(boolean force)
public void setHomeRotation(double[] rotVals)
rotVals -
protected boolean rotate(int axis,
double radians,
boolean force)
axis - radians -
protected double getMovementRate()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||