This extension requires and active CameraController extension implementation.

Accessors

enabled

get enabled(): boolean
set enabled(value: boolean)

Enables/disables the extension.

Returns: boolean

visible

get visible(): boolean
set visible(value: boolean)

Gets and sets the visbility of the actual section box.

Returns: boolean

Methods

getBox

getBox(): Box3

Gets the current section box bounds.

Returns: Box3

on

on(e: CameraEvent, handler: (data: boolean) => void)

Function for subscribing to camera events.

Parameters

Returns: void

removeListener

removeListener(e: CameraEvent, handler: (data: unknown) => void)

Function for un-subscribing from camera events.

Parameters

  • e: CameraEvent
  • handler: The handler for the events to unsubscribe

Returns: void

setBox

setBox(targetBox: Box3, offset = 0): void

Sets the section box to the specified bounds Parameters

  • targetBox: Box3
  • optional offset: Linear tolerance

Returns: void

toggle

toggle(): void

Enables/disables the section tool.

Returns: void

Typedefs

SectionToolEvent

enum SectionToolEvent {
  DragStart = 'section-box-drag-start',
  DragEnd = 'section-box-drag-end',
  Updated = 'section-box-changed',
}

Events that the extension can emit.

SectionToolEventPayload

interface SectionToolEventPayload {
  [SectionToolEvent.DragStart]: void;
  [SectionToolEvent.DragEnd]: void;
  [SectionToolEvent.Updated]: Plane[];
}

Mapping SectionToolEvent types to handler argument type