Options
All
  • Public
  • Public/Protected
  • All
Menu

Class WebXRMeshDetector

The mesh detector is used to detect meshes in the real world when in AR

Hierarchy

Implements

Index

Constructors

constructor

Properties

disableAutoAttachSearch playground for disableAutoAttach

disableAutoAttach: boolean

Should auto-attach be disabled?

isDisposedSearch playground for isDisposed

isDisposed: boolean

Is this feature disposed?

onMeshAddedObservableSearch playground for onMeshAddedObservable

onMeshAddedObservable: Observable<IWebXRVertexData>

Observers registered here will be executed when a new mesh was added to the session

onMeshRemovedObservableSearch playground for onMeshRemovedObservable

onMeshRemovedObservable: Observable<IWebXRVertexData>

Observers registered here will be executed when a mesh is no longer detected in the session

onMeshUpdatedObservableSearch playground for onMeshUpdatedObservable

onMeshUpdatedObservable: Observable<IWebXRVertexData>

Observers registered here will be executed when an existing mesh updates

xrNativeFeatureNameSearch playground for xrNativeFeatureName

xrNativeFeatureName: string

The name of the native xr feature name (like anchor, hit-test, or hand-tracking)

Static Readonly NameSearch playground for Name

Name: "xr-mesh-detection" = "xr-mesh-detection"

The module's name

Static Readonly VersionSearch playground for Version

Version: 1 = 1

The (Babylon) version of this module. This is an integer representing the implementation version. This number does not correspond to the WebXR specs version

Accessors

attached

  • get attached(): boolean

Methods

attachSearch playground for attach

  • attach(force?: boolean): boolean
  • attach this feature

    Parameters

    • Optional force: boolean

      should attachment be forced (even when already attached)

    Returns boolean

    true if successful, false is failed or already attached

detachSearch playground for detach

  • detach(): boolean

disposeSearch playground for dispose

  • dispose(): void

isCompatibleSearch playground for isCompatible

  • isCompatible(): boolean
  • This function will be executed during before enabling the feature and can be used to not-allow enabling it. Note that at this point the session has NOT started, so this is purely checking if the browser supports it

    Returns boolean

    whether or not the feature is compatible in this environment

Legend

  • Constructor
  • Property
  • Method
  • Property
  • Method
  • Inherited property
  • Inherited method
  • Static property
  • Static method