|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectgov.nasa.worldwind.awt.AbstractViewInputHandler
gov.nasa.worldwind.awt.BasicViewInputHandler
gov.nasa.worldwind.view.firstperson.FlyViewInputHandler
public class FlyViewInputHandler
| Nested Class Summary | |
|---|---|
class |
FlyViewInputHandler.ResetPitchActionListener
|
class |
FlyViewInputHandler.RollActionListener
Input handler to handle user input that changes Roll. |
| Constructor Summary | |
|---|---|
FlyViewInputHandler()
|
|
| Method Summary | |
|---|---|
void |
addAnimator(Animator animator)
Add an Animator to this ViewInputHandler. |
void |
apply()
Implementations are expected to apply any changes to the View state prior to the View
setting the modelview matrix for rendering the current frame. |
void |
goTo(Position lookAtPos,
double distance)
Animate to the specified position. |
protected void |
handleViewStopped()
|
boolean |
isAnimating()
Determine if there are any animations active in the View. |
void |
lookAt(Position lookAtPos,
long timeToMove)
|
protected void |
onHorizontalTranslateAbs(Angle latitudeChange,
Angle longitudeChange,
ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
onHorizontalTranslateRel(Angle forwardChange,
Angle sideChange,
ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
onHorizontalTranslateRel(double forwardInput,
double sideInput,
double totalForwardInput,
double totalSideInput,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttributes)
|
protected void |
onMoveTo(Position focalPosition,
ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
onMoveTo(Position focalPosition,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
onResetHeading(ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
onResetHeadingPitchRoll(ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
onResetPitch(ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
onRoll(Angle rollChange,
ViewInputAttributes.ActionAttributes actionAttribs)
Called when the roll changes due to user input. |
protected void |
onRoll(double rollInput,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttributes)
Called when the roll changes due to user input. |
protected void |
onRotateView(Angle headingChange,
Angle pitchChange,
ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
onRotateView(double headingInput,
double pitchInput,
double totalHeadingInput,
double totalPitchInput,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttributes)
|
protected void |
onVerticalTranslate(double translateChange,
double totalTranslateChange,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
onVerticalTranslate(double translateChange,
ViewInputAttributes.ActionAttributes actionAttribs)
|
protected void |
setEyePosition(AnimationController animControl,
View view,
Position position,
ViewInputAttributes.ActionAttributes attrib)
|
protected void |
setHeading(View view,
AnimationController animControl,
Angle heading,
ViewInputAttributes.ActionAttributes attrib)
|
protected void |
setPitch(View view,
AnimationController animControl,
Angle pitch,
ViewInputAttributes.ActionAttributes attrib)
|
protected void |
setRoll(View view,
AnimationController animControl,
Angle roll,
ViewInputAttributes.ActionAttributes attrib)
Set the roll in a view. |
void |
stopAnimators()
Stops any animations that are active in this View |
protected void |
stopGoToAnimators()
|
protected void |
stopUserInputAnimators()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected static final String ACTION_RESET_PITCH
protected static final double DEFAULT_KEY_HORIZONTAL_TRANSLATE_MAX_VALUE
protected static final double DEFAULT_KEY_HORIZONTAL_TRANSLATE_MAX_VALUE_SLOW
protected static final double DEFAULT_KEY_HORIZONTAL_TRANSLATE_MIN_VALUE
protected static final double DEFAULT_KEY_HORIZONTAL_TRANSLATE_MIN_VALUE_SLOW
protected static final double DEFAULT_KEY_TRANSLATE_SMOOTHING_VALUE
protected static final double DEFAULT_KEY_VERTICAL_TRANSLATE_MAX_VALUE
protected static final double DEFAULT_KEY_VERTICAL_TRANSLATE_MIN_VALUE
protected static double DEFAULT_MOUSE_HORIZONTAL_TRANSLATE_MAX_VALUE
protected static double DEFAULT_MOUSE_HORIZONTAL_TRANSLATE_MIN_VALUE
protected static final double DEFAULT_MOUSE_ROTATE_MAX_VALUE
protected static final double DEFAULT_MOUSE_ROTATE_MIN_VALUE
protected static final double DEFAULT_MOUSE_VERTICAL_TRANSLATE_MAX_VALUE
protected static final double DEFAULT_MOUSE_VERTICAL_TRANSLATE_MIN_VALUE
protected static final double DEFAULT_MOUSE_WHEEL_VERTICAL_TRANSLATE_VALUE_MAX
protected static final double DEFAULT_MOUSE_WHEEL_VERTICAL_TRANSLATE_VALUE_MAX_OSX
protected static final double DEFAULT_MOUSE_WHEEL_VERTICAL_TRANSLATE_VALUE_MIN
protected static final double DEFAULT_MOUSE_WHEEL_VERTICAL_TRANSLATE_VALUE_MIN_OSX
protected static final ViewInputAttributes.ActionAttributes.KeyAction DEFAULT_RESET_PITCH_KEY_ACT
public static final ViewInputAttributes.ActionAttributes.KeyAction[] resetPitchEvents
protected static final String VIEW_ANIM_APP
protected static final String VIEW_ANIM_HEADING
protected static final String VIEW_ANIM_PAN
protected static final String VIEW_ANIM_PITCH
protected static final String VIEW_ANIM_POSITION
protected static final String VIEW_ANIM_ROLL
| Constructor Detail |
|---|
public FlyViewInputHandler()
| Method Detail |
|---|
public void addAnimator(Animator animator)
ViewInputHandlerAnimator to this ViewInputHandler.
This method does not start the Animator. Starting the
Animator is the responsibility of the application.
This method is here primarily for use by the View. Applications should call
View.addAnimator(gov.nasa.worldwind.animation.Animator) to add an animtion to the
view.
animator - the Animator to be addedpublic void apply()
ViewInputHandlerView state prior to the View
setting the modelview matrix for rendering the current frame.
apply in interface ViewInputHandlerapply in class BasicViewInputHandler
public void goTo(Position lookAtPos,
double distance)
ViewInputHandlerView to look
at the given position from the given elevation.
goTo in interface ViewInputHandlergoTo in class BasicViewInputHandlerlookAtPos - The position to animate the view to look at.distance - The elevation to look at the position from.protected void handleViewStopped()
handleViewStopped in class BasicViewInputHandlerpublic boolean isAnimating()
ViewInputHandlerView.
public void lookAt(Position lookAtPos,
long timeToMove)
protected void onHorizontalTranslateAbs(Angle latitudeChange,
Angle longitudeChange,
ViewInputAttributes.ActionAttributes actionAttribs)
onHorizontalTranslateAbs in class BasicViewInputHandler
protected void onHorizontalTranslateRel(Angle forwardChange,
Angle sideChange,
ViewInputAttributes.ActionAttributes actionAttribs)
onHorizontalTranslateRel in class AbstractViewInputHandler
protected void onHorizontalTranslateRel(double forwardInput,
double sideInput,
double totalForwardInput,
double totalSideInput,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttributes)
onHorizontalTranslateRel in class BasicViewInputHandler
protected void onMoveTo(Position focalPosition,
ViewInputAttributes.ActionAttributes actionAttribs)
onMoveTo in class BasicViewInputHandler
protected void onMoveTo(Position focalPosition,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttribs)
onMoveTo in class BasicViewInputHandlerprotected void onResetHeading(ViewInputAttributes.ActionAttributes actionAttribs)
onResetHeading in class BasicViewInputHandlerprotected void onResetHeadingPitchRoll(ViewInputAttributes.ActionAttributes actionAttribs)
onResetHeadingPitchRoll in class BasicViewInputHandlerprotected void onResetPitch(ViewInputAttributes.ActionAttributes actionAttribs)
protected void onRoll(Angle rollChange,
ViewInputAttributes.ActionAttributes actionAttribs)
rollChange - Change in roll.actionAttribs - Action that caused the change.
protected void onRoll(double rollInput,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttributes)
rollInput - Change in roll.deviceAttributes - Attributes of the input device.actionAttributes - Action that caused the change.
protected void onRotateView(Angle headingChange,
Angle pitchChange,
ViewInputAttributes.ActionAttributes actionAttribs)
onRotateView in class AbstractViewInputHandler
protected void onRotateView(double headingInput,
double pitchInput,
double totalHeadingInput,
double totalPitchInput,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttributes)
onRotateView in class AbstractViewInputHandler
protected void onVerticalTranslate(double translateChange,
double totalTranslateChange,
ViewInputAttributes.DeviceAttributes deviceAttributes,
ViewInputAttributes.ActionAttributes actionAttribs)
onVerticalTranslate in class AbstractViewInputHandler
protected void onVerticalTranslate(double translateChange,
ViewInputAttributes.ActionAttributes actionAttribs)
onVerticalTranslate in class BasicViewInputHandler
protected void setEyePosition(AnimationController animControl,
View view,
Position position,
ViewInputAttributes.ActionAttributes attrib)
protected void setHeading(View view,
AnimationController animControl,
Angle heading,
ViewInputAttributes.ActionAttributes attrib)
protected void setPitch(View view,
AnimationController animControl,
Angle pitch,
ViewInputAttributes.ActionAttributes attrib)
protected void setRoll(View view,
AnimationController animControl,
Angle roll,
ViewInputAttributes.ActionAttributes attrib)
view - View to modify.animControl - Animator controller for the view.roll - new roll value.attrib - action that caused the roll to change.public void stopAnimators()
ViewInputHandlerView
protected void stopGoToAnimators()
protected void stopUserInputAnimators()
|
NASA World Wind | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||