DelegateInputHandler.flight constructor
DelegateInputHandler.flight(
- ThermionViewer viewer, {
- PickDelegate? pickDelegate,
- bool freeLook = false,
- double panSensitivity = 0.1,
- double zoomSensitivity = 0.1,
- double movementSensitivity = 0.1,
- double rotateSensitivity = 0.01,
- double? clampY,
- ThermionEntity? entity,
Implementation
factory DelegateInputHandler.flight(ThermionViewer viewer,
{PickDelegate? pickDelegate,
bool freeLook = false,
double panSensitivity = 0.1,
double zoomSensitivity = 0.1,
double movementSensitivity = 0.1,
double rotateSensitivity = 0.01,
double? clampY,
ThermionEntity? entity}) =>
DelegateInputHandler(
viewer: viewer,
pickDelegate: pickDelegate,
transformDelegate: FreeFlightInputHandlerDelegate(viewer,
clampY: clampY,
entity: entity,
rotationSensitivity: rotateSensitivity,
zoomSensitivity:zoomSensitivity,
panSensitivity: panSensitivity,
movementSensitivity: movementSensitivity),
actions: {
InputType.MMB_HOLD_AND_MOVE: InputAction.ROTATE,
InputType.SCROLLWHEEL: InputAction.ZOOM,
InputType.LMB_HOLD_AND_MOVE: InputAction.TRANSLATE,
InputType.KEYDOWN_A: InputAction.TRANSLATE,
InputType.KEYDOWN_W: InputAction.TRANSLATE,
InputType.KEYDOWN_S: InputAction.TRANSLATE,
InputType.KEYDOWN_D: InputAction.TRANSLATE,
InputType.SCALE1: InputAction.TRANSLATE,
InputType.SCALE2: InputAction.ZOOM,
if (freeLook) InputType.POINTER_MOVE: InputAction.ROTATE,
});