Assembly: DigitalRune.Geometry (in DigitalRune.Geometry.dll) Version: 126.96.36.199 (188.8.131.5290)
One-sided and two-sided meshes: Per default, the collision detection treats the triangle mesh as one-sided (IsTwoSided is falseFalsefalsefalse (False in Visual Basic)); that means, only the front side of a triangle is solid. If the collision detection is used in a physics simulation, then objects can pass through the back side of a triangle. IsTwoSided can be set to trueTruetruetrue (True in Visual Basic) to treat the mesh as two-sided (double-sided).
Meshes are hollow: Further, meshes are not treated as solid volumes. For example if a the triangle mesh represents a sphere and another object is inside the sphere but does not touch any triangles, then no collision is reported.
Spatial Partitioning: A spatial partitioning method (see Partition can be used to improve runtime performance if the Mesh consists of a lot of triangles. A spatial partition improves the collision detection speed at the cost of additional memory. If Partition is nullNothingnullptra null reference (Nothing in Visual Basic), no spatial partitioning method is used (which is the default). If a spatial partitioning scheme should be used, the property Partition must be set to a ISpatialPartition<(Of <(<'T>)>)> instance. The items in the spatial partition will be the indices of the mesh triangles. The triangle mesh shape will automatically fill and update the spatial partition. Following example shows how a complex triangle mesh shape can be improved by using an AABB tree:
myTriangleMeshShape.Partition = new AabbTree<int>();
Cloning: A ITriangleMesh implements ICloneable then ITriangleMesh is cloned (deep copy); otherwise only the reference to ITriangleMesh is copied (shallow copy). If a Partition is in use, the spatial partition will be cloned if it implements ICloneable. If it does not implement ICloneable, the clone will not have a spatial partition.can be cloned. When the contained