API

Interface IWebXRMeshDetectorOptions

Options used in the mesh detector module

interface IWebXRMeshDetectorOptions {
    convertCoordinateSystems?: boolean;
    doNotRemoveMeshesOnSessionEnded?: boolean;
    generateMeshes?: boolean;
    preferredDetectorOptions?: any;
    worldParentNode?: TransformNode;
}
Index
convertCoordinateSystems?: boolean

If set to true, WebXRMeshDetector will convert coordinate systems for meshes. If not defined, mesh conversions from right handed to left handed coordinate systems won't be conducted. Right handed mesh data will be available through IWebXRVertexData.xrMesh.

doNotRemoveMeshesOnSessionEnded?: boolean

If set to true a reference of the created meshes will be kept until the next session starts If not defined, meshes will be removed from the array when the feature is detached or the session ended.

generateMeshes?: boolean

If set to true, the feature will generate meshes for the detected data. Note that this might be time consuming, as the mesh's vertex data will be updated on every change. Setting this to true will also set convertCoordinateSystems to true. Note - the meshes will NOT be disposed automatically when the feature is detached or the session ended.

preferredDetectorOptions?: any

Preferred detector configuration, not all preferred options will be supported by all platforms. Babylon native only!

worldParentNode?: TransformNode

The node to use to transform the local results to world coordinates