Sphere |
public class SphereModelNode : ModelNode
The SphereModelNode type exposes the following members.
Name | Description | |
---|---|---|
SphereModelNode | Constructor | |
SphereModelNode(String) | Constructor | |
SphereModelNode(Material, String) | Constructor | |
SphereModelNode(Vector3, Single, Material, String) | Constructor |
Name | Description | |
---|---|---|
CenterPosition | Gets or sets a center position of the sphere. | |
Radius | Gets or sets a radius of the sphere. By default set to 1. | |
Segments | Gets or sets the number of segments that define the sphere | |
UseSharedSphereMesh | Gets or sets a Boolean that specifies that when Segments is set to 30, then a shared mesh with center at (0, 0, 0), radius of 1 and 30 segments is used for this sphere (this uses the same vertex and index buffer for all boxes with shared mesh). In this case the final position and size is set by using a mesh transformation. When false, then a new mesh instance is created that has the center and size that are specified in this sphere model. Default value is true. |
Name | Description | |
---|---|---|
GetCenterPosition |
Returns center position of this sphere.
When applyTransformation is true (by default), then center position is also transformed by Transform.
(Overrides ModelNodeGetCenterPosition(Boolean, Boolean)) | |
OnInitializeSceneResources |
Initializes resources with the specified Scene and GpuDevice.
This method can be override and is called from InitializeSceneResources(Scene) method.
(Overrides ModelNodeOnInitializeSceneResources(Scene, VulkanDevice)) | |
UpdateLocalBoundingBox |
UpdateLocalBoundingBox
(Overrides ModelNodeUpdateLocalBoundingBox) | |
UpdateMesh |
UpdateMesh method recreates the mesh based on the current object properties.
The method should be overriden in the derived class that provides its own mesh generation.
(Overrides ModelNodeUpdateMesh) |