Package jsim.collision
Class ColliderShape
java.lang.Object
jsim.collision.ColliderShape
- Direct Known Subclasses:
BoxCollider,PlaneCollider,SphereCollider
A collision shape attached to a rigid body.
Shapes are defined in body-local space. The physics world transforms them to world space when building AABBs and running narrowphase tests.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumShape type tag for fast dispatch in narrowphase. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract voidcomputeAABB(edu.wpi.first.math.geometry.Pose3d pose, double[] out) Compute the world-space AABB of this shape given the body's pose.abstract ColliderShape.TypegetType()The shape type of this collider.
-
Constructor Details
-
ColliderShape
public ColliderShape()
-
-
Method Details
-
getType
The shape type of this collider.- Returns:
- this shape's type tag
-
computeAABB
public abstract void computeAABB(edu.wpi.first.math.geometry.Pose3d pose, double[] out) Compute the world-space AABB of this shape given the body's pose.- Parameters:
pose- world-space pose of the body (position in metres, orientation as quaternion)out- receives [minX, minY, minZ, maxX, maxY, maxZ] in metres
-