Type alias ViewportControls

ViewportControls: {
    dispose: ((delta) => void);
    domElement: HTMLCanvasElement;
    enabled: boolean;
    focus: ((...args) => void);
    object: THREE.Object3D<THREE.Object3DEventMap>;
    setCamera: ((camera) => void);
    update: ((delta) => void);
} & THREE.EventDispatcher<{
    change: never;
}> & Test & AddDebug

The ViewportControls controls an object in the viewport. It's usually the camera.

Type declaration

  • dispose: ((delta) => void)
      • (delta): void
      • Dispose the controls and its event listeners.

        Parameters

        • delta: number

        Returns void

  • domElement: HTMLCanvasElement

    Reference to the canvas element where the controls are attached. I.e. where pointer events are listened.

  • enabled: boolean

    Whether the controls are enabled or not.

    Default

    true
    
  • focus: ((...args) => void)
      • (...args): void
      • Focus the controls on the given target.

        Parameters

        • Rest ...args: any[]

          Additional arguments.

        Returns void

  • object: THREE.Object3D<THREE.Object3DEventMap>

    Object that is begin controlled. Usually the camera.

  • setCamera: ((camera) => void)
      • (camera): void
      • Set the camera to be used by this renderer.

        Parameters

        • camera: THREE.Camera

          New camera to be used.

        Returns void

  • update: ((delta) => void)
      • (delta): void
      • Call this on every frame to update the controls.

        Parameters

        • delta: number

        Returns void

Generated using TypeDoc