Class EpaPenetrationDepth

java.lang.Object
com.github.stephengold.joltjni.JoltPhysicsObject
com.github.stephengold.joltjni.EpaPenetrationDepth
All Implemented Interfaces:
ConstJoltPhysicsObject, AutoCloseable, Comparable<JoltPhysicsObject>

public class EpaPenetrationDepth extends JoltPhysicsObject
Implement the Expanding Polytope Algorithm. (native type: EPAPenetrationDepth)
  • Constructor Details

    • EpaPenetrationDepth

      public EpaPenetrationDepth()
      Instantiate a default implementation.
  • Method Details

    • getPenetrationDepth

      public boolean getPenetrationDepth(PointConvexSupport aExcluding, Sphere aIncluding, float convexRadiusA, PointConvexSupport bExcluding, Sphere bIncluding, float convexRadiusB, float collisionToleranceSq, float penetrationTolerance, Vec3 iov, Vec3 storePointA, Vec3 storePointB)
      Perform the GJK and EPA steps on a pair of points.
      Parameters:
      aExcluding - point A without convex radius (not null, unaffected)
      aIncluding - point A with convex radius (not null, unaffected)
      convexRadiusA - the convex radius of point A
      bExcluding - point B without convex radius (not null, unaffected)
      bIncluding - point B with convex radius (not null, unaffected)
      convexRadiusB - the convex radius of point B
      collisionToleranceSq - the square of the collision tolerance
      penetrationTolerance - the penetration tolerance
      iov - the direction vector (not null, modified)
      storePointA - storage for the point on point A (not null, modified)
      storePointB - storage for the point on point B (not null, modified)
      Returns:
      true if the points intersect, otherwise false
    • getPenetrationDepth

      public boolean getPenetrationDepth(Sphere aExcluding, Sphere aIncluding, float convexRadiusA, Sphere bExcluding, Sphere bIncluding, float convexRadiusB, float collisionToleranceSq, float penetrationTolerance, Vec3 iov, Vec3 storePointA, Vec3 storePointB)
      Perform the GJK and EPA steps on a pair of spheres.
      Parameters:
      aExcluding - sphere A without convex radius (not null, unaffected)
      aIncluding - sphere A with convex radius (not null, unaffected)
      convexRadiusA - the convex radius of sphere A
      bExcluding - sphere B without convex radius (not null, unaffected)
      bIncluding - sphere B with convex radius (not null, unaffected)
      convexRadiusB - the convex radius of sphere B
      collisionToleranceSq - the square of the collision tolerance
      penetrationTolerance - the penetration tolerance
      iov - the direction vector (not null, modified)
      storePointA - storage for the point on sphere A (not null, modified)
      storePointB - storage for the point on sphere B (not null, modified)
      Returns:
      true if the spheres intersect, otherwise false
    • getPenetrationDepth

      public boolean getPenetrationDepth(Sphere aExcluding, Sphere aIncluding, float convexRadiusA, TransformedAaBox bExcluding, AddConvexRadiusTab bIncluding, float convexRadiusB, float collisionToleranceSq, float penetrationTolerance, Vec3 iov, Vec3 storePointA, Vec3 storePointB)
      Perform the GJK and EPA steps on a sphere and a transformed box.
      Parameters:
      aExcluding - the sphere without convex radius (not null, unaffected)
      aIncluding - the sphere with convex radius (not null, unaffected)
      convexRadiusA - the convex radius of the sphere
      bExcluding - the box without convex radius (not null, unaffected)
      bIncluding - the box with convex radius (not null, unaffected)
      convexRadiusB - the convex radius of the box
      collisionToleranceSq - the square of the collision tolerance
      penetrationTolerance - the penetration tolerance
      iov - the direction vector (not null, modified)
      storePointA - storage for the point on the sphere (not null, modified)
      storePointB - storage for the point on the box (not null, modified)
      Returns:
      true if the box and sphere intersect, otherwise false
    • getPenetrationDepth

      public boolean getPenetrationDepth(TransformedAaBox aExcluding, AddConvexRadiusTab aIncluding, float convexRadiusA, TransformedAaBox bExcluding, AddConvexRadiusTab bIncluding, float convexRadiusB, float collisionToleranceSq, float penetrationTolerance, Vec3 iov, Vec3 storePointA, Vec3 storePointB)
      Perform the GJK and EPA steps on a pair of transformed boxes.
      Parameters:
      aExcluding - box A without convex radius (not null, unaffected)
      aIncluding - box A with convex radius (not null, unaffected)
      convexRadiusA - the convex radius of box A
      bExcluding - box B without convex radius (not null, unaffected)
      bIncluding - box B with convex radius (not null, unaffected)
      convexRadiusB - the convex radius of box B
      collisionToleranceSq - the square of the collision tolerance
      penetrationTolerance - the penetration tolerance
      iov - the direction vector (not null, modified)
      storePointA - storage for the point on box A (not null, modified)
      storePointB - storage for the point on box B (not null, modified)
      Returns:
      true if the boxes intersect, otherwise false
    • getPenetrationDepth

      public boolean getPenetrationDepth(TransformedAaBox aExcluding, TransformedAaBox aIncluding, float convexRadiusA, TransformedSphere bExcluding, TransformedSphere bIncluding, float convexRadiusB, float collisionToleranceSq, float penetrationTolerance, Vec3 iov, Vec3 storePointA, Vec3 storePointB)
      Perform the GJK and EPA steps on a transformed box and a transformed sphere.
      Parameters:
      aExcluding - the box without convex radius (not null, unaffected)
      aIncluding - the box with convex radius (not null, unaffected)
      convexRadiusA - the convex radius of the box
      bExcluding - the sphere without convex radius (not null, unaffected)
      bIncluding - the sphere with convex radius (not null, unaffected)
      convexRadiusB - the convex radius of the sphere
      collisionToleranceSq - the square of the collision tolerance
      penetrationTolerance - the penetration tolerance
      iov - the direction vector (not null, modified)
      storePointA - storage for the point on the box (not null, modified)
      storePointB - storage for the point on the sphere (not null, modified)
      Returns:
      true if the box and sphere intersect, otherwise false