Class CapsuleColliderTests
Class collecting all tests for the CapsuleCollider
Inheritance
Namespace: Unity.Physics.Tests.Collision.Colliders
Syntax
public class CapsuleColliderTests
Methods
TestCapsuleColliderCalculateAabbLocal()
Test if the local AABB of the CapsuleCollider is calculated correctly.
Declaration
public void TestCapsuleColliderCalculateAabbLocal()
TestCapsuleColliderCalculateAabbTransformed()
Test whether the AABB of the transformed CapsuleCollider is calculated correctly.
Declaration
public void TestCapsuleColliderCalculateAabbTransformed()
TestCapsuleColliderCreate()
Test if all attributes are set as expected when creating a new CapsuleCollider.
Declaration
public void TestCapsuleColliderCreate()
TestCapsuleColliderCreateInvalid()
Test if CapsuleCollider throws expected exceptions when created with invalid arguments
Declaration
public void TestCapsuleColliderCreateInvalid()
TestCapsuleColliderMassProperties()
Test whether the inertia tensor of the CapsuleCollider is calculated correctly.
Declaration
public void TestCapsuleColliderMassProperties()
Remarks
Used the formula from the following article as reference: https://www.gamedev.net/articles/programming/math-and-physics/capsule-inertia-tensor-r3856/ NOTE: There is an error in eq. 14 of the article: it should be H^2 / 4 instead of H^2 / 2 in Ixx and Izz.