Table of Contents

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

hullOrigin Vector3d
hullRotation FixedQuaternion
hullLocalPoints ReadOnlySpan<Vector3d>
triangleVertexIndices ReadOnlySpan<int>
hullInteriorLocalPoint Vector3d
point FixedPointAnchor

Returns

bool

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

hullOrigin Vector3d
hullRotation FixedQuaternion
hullLocalPoints ReadOnlySpan<Vector3d>
triangleVertexIndices ReadOnlySpan<int>
edgeVertexPairs ReadOnlySpan<int>
capsuleCenter Vector3d
capsuleRotation FixedQuaternion
capsuleLocalAxisDirection Vector3d
capsuleAxisLength Fixed64
capsuleRadius Fixed64
contact FixedContactAnchors

Returns

bool

Remarks

The returned normal points from the hull toward the capsule. Hull points remain in their canonical local frame throughout the exact SAT.

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

firstOrigin Vector3d
firstRotation FixedQuaternion
firstLocalPoints ReadOnlySpan<Vector3d>
firstTriangleVertexIndices ReadOnlySpan<int>
firstEdgeVertexPairs ReadOnlySpan<int>
secondOrigin Vector3d
secondRotation FixedQuaternion
secondLocalPoints ReadOnlySpan<Vector3d>
secondTriangleVertexIndices ReadOnlySpan<int>
secondEdgeVertexPairs ReadOnlySpan<int>
contact FixedContactAnchors

Returns

bool