Click or drag to resize
AB4D logo

SphereVisual3DCreateCachedSphereMesh Method

CreateCachedSphereMesh generates the MeshGeometry3D for a sphere with specified segments count that will be used as cached mesh.

Namespace: Ab3d.Visuals
Assembly: Ab3d.PowerToys (in Ab3d.PowerToys.dll) Version: 11.2.9104.2045
Syntax
C#
public static MeshGeometry3D CreateCachedSphereMesh(
	int segmentsCount
)

Parameters

segmentsCount  Int32
number of segments

Return Value

MeshGeometry3D
created MeshGeometry3D
Remarks

CreateCachedSphereMesh generates the MeshGeometry3D for a sphere with specified segments count that will be used as cached mesh.

SphereVisual3D can cached only one instance of MeshGeometry3D. Because it is possible to specify the number of segments that are used to create the sphere MeshGeometry3D, SphereVisual3D can use the cached mesh only if it has the same number of segments as the cached mesh. SphereVisual3D creates the cached mesh the first time it is used - using the number of segments specified for the first SphereVisual3D. If you would like to control which sphere is cached, you can manually call this method to manually create the sphere MeshGeometry3D with the specified segments count.

See Also