Class GizmoViewportInteraction

The GizmoViewportInteraction implements a ViewportInteractionBase that renders InteractiveGizmo to interact with scene objects.

Interactive gizmos are interactable controls in the scene such as the move and rotate gizmos. Users can extend handles by using the interactiveGizmo decorator on a subclass of InteractiveGizmo

Hierarchy (view full)

Constructors

Properties

onSceneSelectionChanged: ((selectedSceneObjects: SceneObject[]) => void)

Triggered when the scene selection changed.

Type declaration

    • (selectedSceneObjects): void
    • Parameters

      • selectedSceneObjects: SceneObject[]

        The new selected objects.

      Returns void

onSceneViewportRedrawRequested: ((request: Const<SceneViewportRedrawRequest>) => void)

Called on viewport redraw request. This is used to update the picking cache on move pivot mode when the camera moves.

viewportRenderer: UIViewportRenderer

The viewport this interaction controls.

kHandleAxesGUISize: number

Accessors

  • get isMovePivotModeEnabled(): boolean
  • Check if the move pivot mode is currently enabled.

    Returns boolean

  • get lastTextureSpaceDragPosition(): Vector2
  • The last drag position in viewport texture space. Note: This is needed as the handle manager is updated outside of the event handling. This should be fixed. The texture space position should be availabel in PostInput to pass through to consuming systems.

    Returns Vector2

  • get viewportCamera(): ViewportCamera
  • The ViewportCamera the interaction controls.

    Returns ViewportCamera

Methods

  • Deactivates the previously selected handles.

    Returns void

  • Disable feature higlight for move pivot snapping.

    Returns void

  • Draws the handles and axes gui.

    Returns void

  • Enable feature highlight for move pivot snapping.

    Returns void

  • Pick the pivot position under the cursor and snaps it to nearest scene feature based on settings.

    Parameters

    Returns void

  • Set the snapping destination that is applied to move handle snapping.

    Parameters

    Returns void

  • Toggle between object move mode and pivot move mode.

    Parameters

    • isEnabled: boolean

      Will the mode be enabled or disabled.

    Returns void

  • Handles updating the position of axes gizmo.

    Returns void

  • Checks the axes gui for projection type change.

    Returns void

  • Returns void

  • Returns void

  • Returns void