ShapeCreator.h 676 B

123456789101112131415161718
  1. // Jolt Physics Library (https://github.com/jrouwe/JoltPhysics)
  2. // SPDX-FileCopyrightText: 2022 Jorrit Rouwe
  3. // SPDX-License-Identifier: MIT
  4. #pragma once
  5. #include <Jolt/Physics/Collision/Shape/MeshShape.h>
  6. namespace ShapeCreator
  7. {
  8. /// Create a mesh shape in the shape of a torus
  9. /// @param inTorusRadius Radius of the torus ring
  10. /// @param inTubeRadius Radius of the torus tube
  11. /// @param inTorusSegments Number of segments around the torus
  12. /// @param inTubeSegments Number of segments around the tube of the torus
  13. /// @return The mesh shape
  14. ShapeRefC CreateTorusMesh(float inTorusRadius, float inTubeRadius, uint inTorusSegments = 16, uint inTubeSegments = 16);
  15. };