ClosestPointTest.h 741 B

12345678910111213141516171819202122
  1. // Jolt Physics Library (https://github.com/jrouwe/JoltPhysics)
  2. // SPDX-FileCopyrightText: 2021 Jorrit Rouwe
  3. // SPDX-License-Identifier: MIT
  4. #pragma once
  5. #include <Tests/Test.h>
  6. // Test that interactively shows the algorithms from the ClosestPoints namespace
  7. class ClosestPointTest : public Test
  8. {
  9. public:
  10. JPH_DECLARE_RTTI_VIRTUAL(JPH_NO_EXPORT, ClosestPointTest)
  11. // Update the test, called before the physics update
  12. virtual void PrePhysicsUpdate(const PreUpdateParams &inParams) override;
  13. private:
  14. void TestLine(Vec3Arg inPosition, Vec3Arg inA, Vec3Arg inB);
  15. void TestTri(Vec3Arg inPosition, Vec3Arg inA, Vec3Arg inB, Vec3Arg inC);
  16. void TestTetra(Vec3Arg inPosition, Vec3Arg inA, Vec3Arg inB, Vec3Arg inC, Vec3Arg inD);
  17. };