AxisTriad

class AxisTriad()

This class provides an interface to the axis triad which is enabled by default. The default functionality orients the camera based on the axis that is clicked. This triad is initialized and associated with an overlay when the view is created. For additional information on overlays please refer to the [[OverlayManager]].

More information can be found here.

Methods

AxisTriad.disable()
disable(): Promise

Disables this [[AxisTriad]].

Returns: Promise

A promise that resolves on completion.
AxisTriad.enable()
enable(): Promise

Enables this [[AxisTriad]].

Returns: Promise

A promise that resolves on completion.
AxisTriad.getAnchor()
getAnchor(): OverlayAnchor

Gets the anchor position for this [[AxisTriad]]. Default position is in the lower left corner.

Returns: OverlayAnchor

The overlay anchor value of the triad.
AxisTriad.getEnabled()
getEnabled(): boolean

Gets the current state of this [[AxisTriad]].

Returns: boolean

true if enabled and false otherwise.
AxisTriad.getOverlayId()
getOverlayId(): number

Gets the overlay id. This id should be considered reserved and not be used by client applications.

Returns: number

The overlay id used by this [[AxisTriad]].
AxisTriad.getSelectionAxis()
getSelectionAxis(selectionItem: (None | SelectionItem)): (None | Axis)

Checks if a selection is part of the axis triad, and return the corresponding axis.

Parameters

selectionItem: (None | SelectionItem)

selection item to check.

Returns: (None | Axis)

Axis if selected, null otherwise.
AxisTriad.insideOverlay()
insideOverlay(mousePos: Point2): boolean

Determines whether or not a point is inside the axis triad overlay

Parameters

mousePos: Point2

Returns: boolean

Boolean indicating whether the provided point is inside the axis triad overlay
AxisTriad.onClickSelection()
onClickSelection(selection: (None | SelectionItem)): Promise

Called when the axis triad is clicked. Realigns the view along the axis selected by selection or does nothing if no axis is selected.

Parameters

selection: (None | SelectionItem)

Returns: Promise

AxisTriad.setAnchor()
setAnchor(anchor: OverlayAnchor): Promise

Sets the anchor position for this [[AxisTriad]].

Parameters

anchor: OverlayAnchor

The anchor position.

Returns: Promise

A promise that resolves on completion.
AxisTriad.setAxisColor()
setAxisColor(axis: Axis, color: Color): Promise

Sets the color of one axis on this [[AxisTriad]]

Parameters

axis: Axis

The axis that will change color

color: Color

The color to set

Returns: Promise