Click or drag to resize
Ab4d.SharpEngine logo

MeshAnalyzerTryCreate Method

TryCreate method tries to create a MeshAnalyzer from the specified mesh.

Namespace: Ab4d.SharpEngine.Utilities
Assembly: Ab4d.SharpEngine (in Ab4d.SharpEngine.dll) Version: 3.2.9386+3a404a3e1ebfa4efd231da7fe6f10dfb23b95dc4
Syntax
C#
public static MeshAnalyzer? TryCreate(
	Mesh mesh
)

Parameters

mesh  Mesh
Mesh

Return Value

MeshAnalyzer
Created MeshAnalyzer or null if mesh does not provide positions and triangle indices.
Remarks

TryCreate method tries to create a MeshAnalyzer from the specified mesh.

If Mesh is a StandardMesh then the MeshAnalyzer is created directly from the mesh.

Otherwise the GetDataChannelArrayT(MeshDataChannelTypes) is called to retrieve the positions and triangle indices from the mesh (note that this may require copying of data). If the positions and triangle indices cannot be retrieved then null is returned.

See Also