PhysicsEngineCreateConvexHullGeometryByDecomposition Method |
Decomposes the provided mesh into a number of convex-hulls.
Namespace:
Demo3D.Visuals
Assembly:
Demo3D.Core (in Demo3D.Core.dll) Version: 15.0.2.11458
Syntaxpublic PhysicsCompoundGeometry CreateConvexHullGeometryByDecomposition(
IMesh mesh,
double margin,
ConvexHullDecompositionProperties props = null
)
Parameters
- mesh
- Type: IMesh
The mesh from which to create the convex-hull geometry. - margin
- Type: SystemDouble
The collision margin for the convex-hulls. - props (Optional)
- Type: ConvexHullDecompositionProperties
The properties to use when performing convex-hull decomposition.
Return Value
Type:
PhysicsCompoundGeometryThe created compound physics geometry, containing convex-hulls.
Remarks
This method first computes the convex-hull decomposition for the specified
mesh. The convex-hull decomposition is then cached so that we only
perform the computationally expensive operations required to generate the convex-hull
decomposition once. The convex-hull decomposition is then used to create the compound of
physics convex-hull geometry.
See Also