API

Class WebXRAbstractFeatureAbstract

This is the base class for all WebXR features. Since most features require almost the same resources and callbacks, this class can be used to simplify the development Note that since the features manager is using the IWebXRFeature you are in no way obligated to use this class

Hierarchy (View Summary)

Implements

Index
dependsOn?: string[]

The dependencies of this feature, if any

disableAutoAttach: boolean = false

Should auto-attach be disabled?

isDisposed: boolean = false

Is this feature disposed?

onFeatureAttachObservable: Observable<IWebXRFeature> = ...

Observers registered here will be executed when the feature is attached

onFeatureDetachObservable: Observable<IWebXRFeature> = ...

Observers registered here will be executed when the feature is detached

  • 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