# FloorplanManager

class `Floorplan.``FloorplanManager`()

  Main interface into the 2D floorplan functionality for the viewer. Can show a 2-dimensional floorplan of a BIM-enabled model. The floorplan display will include an avatar that represents the camera position of the 3D view.

  ## Index

  Methods

  - `activate`
  - `deactivate`
  - `getAvatarNodeId`
  - `getConfiguration`
  - `getCurrentFloorNodeId`
  - `getFloorLock`
  - `insideOverlay`
  - `isActive`
  - `setAutoActivate`
  - `setAvatarColor`
  - `setAvatarOpacity`
  - `setAvatarOutlineColor`
  - `setAvatarScale`
  - `setBackgroundColor`
  - `setBackgroundOpacity`
  - `setBorderColor`
  - `setBorderOpacity`
  - `setConfiguration`
  - `setCustomAvatar`
  - `setFixedAvatarScale`
  - `setFloorLock`
  - `setFloorplanOrientation`
  - `setOverlayAnchor`
  - `setOverlayFeetPerPixel`
  - `setOverlayOffset`
  - `setOverlaySize`
  - `setTrackCameraEnabled`
  - `setUseTightBoundings`
  - `setZoomLevel`
  - `snapAvatarToPoint`

## Methods

`Floorplan.FloorplanManager.``activate`()
  activate(): Promise

  Activate the floorplan overlay.

  Returns: Promise

`Floorplan.FloorplanManager.``deactivate`()
  deactivate(): Promise

  Deactivate the floorplan overlay. Once explicitly deactivated via this call, auto-activation will be suppressed for any new model that is loaded. Auto-activation can be reenabled by calling [[setAutoActivate]].

  Returns: Promise

`Floorplan.FloorplanManager.``getAvatarNodeId`()
  getAvatarNodeId(): (None | number)

  Gets the [[NodeId]] of the floorplan avatar.

  Returns: (None | number)

`Floorplan.FloorplanManager.``getConfiguration`()
  getConfiguration(): `FloorplanConfig`

  Returns a copy of the current floorplan configuration.

  Returns: `FloorplanConfig`

`Floorplan.FloorplanManager.``getCurrentFloorNodeId`()
  getCurrentFloorNodeId(): (None | number)

  Gets the [[NodeId]] of the current storey.

  Returns: (None | number)

`Floorplan.FloorplanManager.``getFloorLock`()
  getFloorLock(): boolean

  Returns `true` if displayed floor has been locked with [[setFloorLock]].

  Returns: boolean

`Floorplan.FloorplanManager.``insideOverlay`()
  insideOverlay(point: `Point2`): boolean

  Returns `true` if the given point is inside the floorplan overlay and `false` otherwise.

  Parameters

  > point: `Point2`

  Returns: boolean

`Floorplan.FloorplanManager.``isActive`()
  isActive(): boolean

  Returns `true` if the [[FloorplanManager]] is fully active.

  Returns: boolean

`Floorplan.FloorplanManager.``setAutoActivate`()
  setAutoActivate(autoActivate: `FloorplanAutoActivation`): Promise

  Sets the auto-activate capability for any models loaded after this call. See [[FloorplanConfig.autoActivate]] for detailed information.

  Parameters

  > autoActivate: `FloorplanAutoActivation`

  Returns: Promise

`Floorplan.FloorplanManager.``setAvatarColor`()
  setAvatarColor(color: `Color`): Promise

  Sets the avatar primary color. See [[FloorplanConfig.avatarColor]] for detailed information.

  Parameters

  > color: `Color`

  Returns: Promise

`Floorplan.FloorplanManager.``setAvatarOpacity`()
  setAvatarOpacity(opacity: number): Promise

  Sets the avatar opacity. See [[FloorplanConfig.avatarOpacity]] for detailed information.

  Parameters

  > opacity: number

  Returns: Promise

`Floorplan.FloorplanManager.``setAvatarOutlineColor`()
  setAvatarOutlineColor(color: `Color`): Promise

  Sets the avatar outline color. See [[FloorplanConfig.avatarOutlineColor]] for detailed information.

  Parameters

  > color: `Color`

  Returns: Promise

`Floorplan.FloorplanManager.``setAvatarScale`()
  setAvatarScale(scale: number): Promise

  Sets the avatar scale. See [[FloorplanConfig.avatarScale]] for detailed information.

  Parameters

  > scale: number

  Returns: Promise

`Floorplan.FloorplanManager.``setBackgroundColor`()
  setBackgroundColor(color: `Color`): Promise

  Sets the overlay background color. See [[FloorplanConfig.backgroundColor]] for detailed information.

  Parameters

  > color: `Color`

  Returns: Promise

`Floorplan.FloorplanManager.``setBackgroundOpacity`()
  setBackgroundOpacity(opacity: number): Promise

  Sets the overlay background opacity. See [[FloorplanConfig.backgroundOpacity]] for detailed information.

  Parameters

  > opacity: number

  Returns: Promise

`Floorplan.FloorplanManager.``setBorderColor`()
  setBorderColor(color: `Color`): Promise

  Sets the overlay border color. See [[FloorplanConfig.borderColor]] for detailed information.

  Parameters

  > color: `Color`

  Returns: Promise

`Floorplan.FloorplanManager.``setBorderOpacity`()
  setBorderOpacity(opacity: number): Promise

  Sets the overlay border opacity. See [[FloorplanConfig.borderOpacity]] for detailed information.

  Parameters

  > opacity: number

  Returns: Promise

`Floorplan.FloorplanManager.``setConfiguration`()
  setConfiguration(config: `FloorplanConfig`): Promise

  Updates the floorplan to use the given configuration. This function allows the user to set all configuration values with a single operation. There are also `set<config-value>()` functions for easily setting individual configuration values.

  Note that when using this function, all settings in the given configuration are used and thus overwrite any individual settings changed with a prior `set<config-value>()` call.

  All values from the passed configuration will be copied as part of this operation.

  Parameters

  > config: `FloorplanConfig`

  Returns: Promise

`Floorplan.FloorplanManager.``setCustomAvatar`()
  setCustomAvatar(customAvatarNodeId: (None | number)): Promise

  Sets a custom avatar. See [[FloorplanConfig.customAvatar]] for detailed information.

  Parameters

  > customAvatarNodeId: (None | number)

  Returns: Promise

`Floorplan.FloorplanManager.``setFixedAvatarScale`()
  setFixedAvatarScale(fixedScale: boolean): Promise

  Sets the avatar size to fixed scale. See [[FloorplanConfig.fixedAvatarScale]] for detailed information.

  Parameters

  > fixedScale: boolean

  Returns: Promise

`Floorplan.FloorplanManager.``setFloorLock`()
  setFloorLock(lock: boolean): Promise

  Locks floorplan to current floor such that changing floors will not change the displayed floorplan.

  Parameters

  > lock: boolean

  Returns: Promise

`Floorplan.FloorplanManager.``setFloorplanOrientation`()
  setFloorplanOrientation(orientation: `FloorplanOrientation`): Promise

  Sets the floorplan display orientation. See [[FloorplanConfig.floorplanOrientation]] for detailed information.

  Parameters

  > orientation: `FloorplanOrientation`

  Returns: Promise

`Floorplan.FloorplanManager.``setOverlayAnchor`()
  setOverlayAnchor(anchor: `OverlayAnchor`): Promise

  Sets the anchor position of the floorplan overlay window. See [[FloorplanConfig.overlayAnchor]] for detailed information.

  Parameters

  > anchor: `OverlayAnchor`

  Returns: Promise

`Floorplan.FloorplanManager.``setOverlayFeetPerPixel`()
  setOverlayFeetPerPixel(feetPerPixel: number): Promise

  Sets the overlay scaling. See [[FloorplanConfig.overlayFeetPerPixel]] for detailed information.

  Parameters

  > feetPerPixel: number

  Returns: Promise

`Floorplan.FloorplanManager.``setOverlayOffset`()
  setOverlayOffset(offset: `Point2`): Promise

  Sets the offset position of the floorplan overlay window. See [[FloorplanConfig.overlayOffset]] for detailed information.

  Parameters

  > offset: `Point2`

  Returns: Promise

`Floorplan.FloorplanManager.``setOverlaySize`()
  setOverlaySize(size: `Point2`, widthUnits: `OverlayUnit`, heightUnits: `OverlayUnit`): Promise

  Sets the size of the floorplan overlay window. See [[FloorplanConfig.overlaySize]] for detailed information.

  Parameters

  > size: `Point2`

  > widthUnits: `OverlayUnit`

  > heightUnits: `OverlayUnit`

  Returns: Promise

`Floorplan.FloorplanManager.``setTrackCameraEnabled`()
  setTrackCameraEnabled(enabled: boolean): Promise

  Sets the floorplan tracking mode. See [[FloorplanConfig.trackCameraEnabled]] for detailed information.

  Parameters

  > enabled: boolean

  Returns: Promise

`Floorplan.FloorplanManager.``setUseTightBoundings`()
  setUseTightBoundings(tightBoundings: boolean): Promise

  Makes floorplans use tight boundings during creation which can result in a better fit for the overlay. This involves recreating any already existing floorplans. This can be significantly more time consuming than using loose boundings if your floors are complex. Defaults to `false`.

  Parameters

  > tightBoundings: boolean

  Returns: Promise

`Floorplan.FloorplanManager.``setZoomLevel`()
  setZoomLevel(zoomLevel: number): Promise

  Sets the overlay zoom level. See [[FloorplanConfig.zoomLevel]] for detailed information.

  Parameters

  > zoomLevel: number

  Returns: Promise

`Floorplan.FloorplanManager.``snapAvatarToPoint`()
  snapAvatarToPoint(point: `Point2`): void

  Moves the camera such that the avatar will appear at the provided point on the overlay. This is only available when the floorplan is not tracking the camera.

  Parameters

  > point: `Point2`

  > > Point in canvas within overlay

  Returns: void

Conversation saved
HOOPSY BETA

### Hello! I'm HOOPSY

Your Docs generative AI assistant. Ask me anything about HOOPS Visualize Web or choose a sample question below to start a conversation:

What is HOOPS Visualize Web?
What are the latest release notes for HOOPS Visualize Web?
How do I start evaluating HOOPS Visualize Web?
How do I write my first sample application?
How can I get assistance?

HOOPSY may store conversations according to OpenAI's policy. Responses may not always be accurate.

HOOPSY is thinking...