Interface XrFeatureSpec
interface XrFeatureSpec {
sessionFeatures?: readonly string[];
create(ctx: XrSessionContext): XrFeatureHandle;
}
sessionFeatures?: readonly string[];
create(ctx: XrSessionContext): XrFeatureHandle;
}
Properties
Optional Readonlysession Features
sessionFeatures?: readonly string[]
Native WebXR session feature descriptors this feature requires, requested as optional features so a session still starts when the device lacks them.
Methods
create
-
Instantiate the feature against a fully-initialised session context.
Parameters
- ctx: XrSessionContext
Returns XrFeatureHandle
An opt-in XR feature. Implementations are free functions returning this spec (e.g.
pointerSelection(options)), so importing one never drags in the others.