ReadonlygeometrySceneGeometry used by this SceneMesh.
ReadonlyidUnique ID of this SceneMesh.
SceneMesh is stored by this ID in SceneModel.meshes.
Optional ReadonlymaterialSceneMaterial used by this SceneMesh.
ReadonlymodelThe SceneModel that contains this SceneMesh.
The SceneObject that uses this SceneMesh.
Gets the RGB color for this SceneMesh.
Each element of the color is in range [0..1].
Sets the RGB color for this SceneMesh.
[0..1].Gets the ID of the SceneGeometry used by this SceneMesh.
Sets the SceneGeometry used by this SceneMesh.
The SceneMesh will already have the SceneGeometry it was created with, and then you can change it to a different SceneGeometry using this setter.
This mechanism allows you to dynamically switch the geometric representation of a SceneMesh at runtime.
When the switch succeeds, SceneMesh.geometry will reference the new SceneGeometry and an SceneEvents.onSceneMeshGeometryChanged event is dispatched on the Scene.
If the given geometryId is invalid, such as when the SceneGeometry does not exist in the SceneModel, an error will be logged and the SceneGeometry will not be changed.
Note that you cannot destroy a SceneGeometry that is currently in use by a SceneMesh.
The ID of the new SceneGeometry to use. Must exist in the SceneModel.
Gets the global RGB color for this SceneMesh, which is the color of the material if it has one, or the local color otherwise.
Gets the global transform matrix for this SceneMesh.
Gets the global opacity factor for this SceneMesh, which is the opacity of the material if it has one,
or the local opacity otherwise. This is a factor in range [0..1].
Gets the ID of the SceneMaterial used by this SceneMesh.
Sets the SceneMaterial used by this SceneMesh.
The SceneMesh will already have the SceneMaterial it was created with, and then you can change it to a different SceneMaterial using this setter.
This mechanism allows you to dynamically switch the geometric representation of a SceneMesh at runtime.
When the switch succeeds, SceneMesh.material will reference the new SceneMaterial and an SceneEvents.onSceneMeshMaterialChanged event is dispatched on the Scene.
If the given materialId is invalid, such as when the SceneMaterial does not exist in the SceneModel, an error will be logged and the SceneMaterial will not be changed.
Note that you cannot destroy a SceneMaterial that is currently in use by a SceneMesh.
The ID of the new SceneMaterial to use. Must exist in the SceneModel.
Gets this SceneMesh's local modeling transform matrix.
Default value is [1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1].
Updates this SceneMesh's local modeling transform matrix.
[1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1].Gets the opacity factor for this SceneMesh.
This is a factor in range [0..1].
Sets the opacity factor for this SceneMesh.
[0..1].Gets the parent SceneTransform of this SceneMesh, or null if this SceneMesh is not parented.
Destroys this SceneMesh.
InternalUpdates the global transform matrix.
Sets the parent transform for this mesh.
The ID of the new parent transform, or null to detach.
Optionalopts: { preserveWorld?: boolean }Options to preserve world transformation.
Gets this SceneMesh as SceneMeshParams.
A mesh in a SceneModel.
See @xeokit/sdk/scene for usage.