FreeCameraKeyboardMoveInput

Manage the keyboard inputs to control the movement of a free camera.

see

http://doc.babylonjs.com/how_to/customizing_camera_inputs

Hierarchy

  • FreeCameraKeyboardMoveInput

Implements

Index

Properties

camera

Find examples in Playground
camera: FreeCamera

Defines the camera the input is attached to.

keysDown

Find examples in Playground
keysDown: number[]

Gets or Set the list of keyboard keys used to control the backward move of the camera.

keysLeft

Find examples in Playground
keysLeft: number[]

Gets or Set the list of keyboard keys used to control the left strafe move of the camera.

keysRight

Find examples in Playground
keysRight: number[]

Gets or Set the list of keyboard keys used to control the right strafe move of the camera.

keysUp

Find examples in Playground
keysUp: number[]

Gets or Set the list of keyboard keys used to control the forward move of the camera.

Methods

attachControl

Find examples in Playground
  • attachControl(element: HTMLElement, noPreventDefault?: boolean): void

checkInputs

Find examples in Playground
  • checkInputs(): void
  • Update the current camera state depending on the inputs that have been used this frame. This is a dynamically created lambda to avoid the performance penalty of looping for inputs in the render loop.

    Returns void

detachControl

Find examples in Playground
  • detachControl(element: Nullable<HTMLElement>): void
  • Detach the current controls from the specified dom element.

    Parameters

    • element: Nullable<HTMLElement>

      Defines the element to stop listening the inputs from

    Returns void

getClassName

Find examples in Playground
  • getClassName(): string

getSimpleName

Find examples in Playground
  • getSimpleName(): string
  • Get the friendly name associated with the input class.

    Returns string

    the input friendly name

Generated using TypeDoc