Class FixedConvexHullRelations
- Namespace
- FixedMathSharp.Geometry
- Assembly
- FixedMathSharp.dll
Provides full-domain relations for rigidly transformed 3D convex hulls.
public static class FixedConvexHullRelations
- Inheritance
-
FixedConvexHullRelations
- Inherited Members
Methods
ContainsPoint(Vector3d, FixedQuaternion, ReadOnlySpan<Vector3d>, ReadOnlySpan<int>, Vector3d, FixedPointAnchor)
Tests whether a point lies in or on a closed convex hull. The supplied interior point determines the accepted side of consistently wound faces.
public static bool ContainsPoint(Vector3d hullOrigin, FixedQuaternion hullRotation, ReadOnlySpan<Vector3d> hullLocalPoints, ReadOnlySpan<int> triangleVertexIndices, Vector3d hullInteriorLocalPoint, FixedPointAnchor point)
Parameters
hullOriginVector3dhullRotationFixedQuaternionhullLocalPointsReadOnlySpan<Vector3d>triangleVertexIndicesReadOnlySpan<int>hullInteriorLocalPointVector3dpointFixedPointAnchor
Returns
TryGetCenteredCapsuleContact(Vector3d, FixedQuaternion, ReadOnlySpan<Vector3d>, ReadOnlySpan<int>, ReadOnlySpan<int>, Vector3d, FixedQuaternion, Vector3d, Fixed64, Fixed64, out FixedContactAnchors)
Attempts to obtain the minimum-translation contact between a rigidly transformed convex hull and a centered capsule.
public static bool TryGetCenteredCapsuleContact(Vector3d hullOrigin, FixedQuaternion hullRotation, ReadOnlySpan<Vector3d> hullLocalPoints, ReadOnlySpan<int> triangleVertexIndices, ReadOnlySpan<int> edgeVertexPairs, Vector3d capsuleCenter, FixedQuaternion capsuleRotation, Vector3d capsuleLocalAxisDirection, Fixed64 capsuleAxisLength, Fixed64 capsuleRadius, out FixedContactAnchors contact)
Parameters
hullOriginVector3dhullRotationFixedQuaternionhullLocalPointsReadOnlySpan<Vector3d>triangleVertexIndicesReadOnlySpan<int>edgeVertexPairsReadOnlySpan<int>capsuleCenterVector3dcapsuleRotationFixedQuaternioncapsuleLocalAxisDirectionVector3dcapsuleAxisLengthFixed64capsuleRadiusFixed64contactFixedContactAnchors
Returns
Remarks
The returned normal points from the hull toward the capsule. Hull points remain in their canonical local frame throughout the exact SAT. Face and edge indices must describe the convex hull's complete boundary; structural validation checks indices, not convexity or topology completeness. A zero-length capsule core is a sphere, including volume containment.
TryGetContact(Vector3d, FixedQuaternion, ReadOnlySpan<Vector3d>, ReadOnlySpan<int>, ReadOnlySpan<int>, Vector3d, FixedQuaternion, ReadOnlySpan<Vector3d>, ReadOnlySpan<int>, ReadOnlySpan<int>, out FixedContactAnchors)
Attempts to obtain the minimum-translation contact between two rigidly transformed convex hulls.
public static bool TryGetContact(Vector3d firstOrigin, FixedQuaternion firstRotation, ReadOnlySpan<Vector3d> firstLocalPoints, ReadOnlySpan<int> firstTriangleVertexIndices, ReadOnlySpan<int> firstEdgeVertexPairs, Vector3d secondOrigin, FixedQuaternion secondRotation, ReadOnlySpan<Vector3d> secondLocalPoints, ReadOnlySpan<int> secondTriangleVertexIndices, ReadOnlySpan<int> secondEdgeVertexPairs, out FixedContactAnchors contact)
Parameters
firstOriginVector3dfirstRotationFixedQuaternionfirstLocalPointsReadOnlySpan<Vector3d>firstTriangleVertexIndicesReadOnlySpan<int>firstEdgeVertexPairsReadOnlySpan<int>secondOriginVector3dsecondRotationFixedQuaternionsecondLocalPointsReadOnlySpan<Vector3d>secondTriangleVertexIndicesReadOnlySpan<int>secondEdgeVertexPairsReadOnlySpan<int>contactFixedContactAnchors