Interface IWebXRNearInteractionOptions
customUtilityLayerScene?: Scene;
disableSwitchOnClick?: boolean;
enableNearInteractionOnAllControllers?: boolean;
farInteractionFeature?: WebXRControllerPointerSelection;
motionControllerOrbMaterial?: Material;
motionControllerTouchMaterialSnippetUrl?: string;
nearInteractionControllerMode?: WebXRNearControllerMode;
preferredHandedness?: any;
useUtilityLayer?: boolean;
xrInput: WebXRInput;
}
Properties
Optionalcustom Utility Layer Scene
If provided, this scene will be used to render meshes.
Optionaldisable Switch On Click
Disable switching the near interaction from one controller to the other. If the preferred hand is set it will be fixed on this hand, and if not it will be fixed on the first controller added to the scene
Optionalenable Near Interaction On All Controllers
Enable near interaction on all controllers instead of switching between them
Optionalfar Interaction Feature
Far interaction feature to toggle when near interaction takes precedence
Optionalmotion Controller Orb Material
Optional material for the motion controller orb, if enabled
Optionalmotion Controller Touch Material Snippet Url
If provided, this URL will be used by Node Material to generate the material for the motion controller orb If not provided, a snippet will be downloaded from the Babylon.js snippet server CDN. The NME JSON file can be found here - https://github.com/BabylonJS/Assets/blob/master/nme/nearInteractionTouchMaterial.json
Optionalnear Interaction Controller Mode
Near interaction mode for motion controllers
Optionalpreferred Handedness
The preferred hand to give the near interaction to. This will be prioritized when the controller initialize. If switch is enabled, it will still allow the user to switch between the different controllers
Optionaluse Utility Layer
Should meshes created here be added to a utility layer or the main scene
xr Input
The xr input to use with this near interaction
Options interface for the near interaction module