Physics3D: Rename ::GeomType to Nz::ColliderType3D

This commit is contained in:
Lynix
2016-10-14 17:27:30 +02:00
parent 9a7767867b
commit 9b48c9ee37
3 changed files with 45 additions and 42 deletions

View File

@@ -54,7 +54,7 @@ namespace Nz
virtual float ComputeVolume() const;
NewtonCollision* GetHandle(PhysWorld3D* world) const;
virtual GeomType GetType() const = 0;
virtual ColliderType3D GetType() const = 0;
Collider3D& operator=(const Collider3D&) = delete;
Collider3D& operator=(Collider3D&&) = delete;
@@ -90,7 +90,7 @@ namespace Nz
float ComputeVolume() const override;
Vector3f GetLengths() const;
GeomType GetType() const override;
ColliderType3D GetType() const override;
template<typename... Args> static BoxCollider3DRef New(Args&&... args);
@@ -114,7 +114,7 @@ namespace Nz
float GetLength() const;
float GetRadius() const;
GeomType GetType() const override;
ColliderType3D GetType() const override;
template<typename... Args> static CapsuleCollider3DRef New(Args&&... args);
@@ -137,7 +137,7 @@ namespace Nz
CompoundCollider3D(Collider3D** geoms, std::size_t geomCount);
const std::vector<Collider3DRef>& GetGeoms() const;
GeomType GetType() const override;
ColliderType3D GetType() const override;
template<typename... Args> static CompoundCollider3DRef New(Args&&... args);
@@ -160,7 +160,7 @@ namespace Nz
float GetLength() const;
float GetRadius() const;
GeomType GetType() const override;
ColliderType3D GetType() const override;
template<typename... Args> static ConeCollider3DRef New(Args&&... args);
@@ -183,7 +183,7 @@ namespace Nz
ConvexCollider3D(const void* vertices, unsigned int vertexCount, unsigned int stride = sizeof(Vector3f), float tolerance = 0.002f, const Matrix4f& transformMatrix = Matrix4f::Identity());
ConvexCollider3D(const void* vertices, unsigned int vertexCount, unsigned int stride, float tolerance, const Vector3f& translation, const Quaternionf& rotation = Quaternionf::Identity());
GeomType GetType() const override;
ColliderType3D GetType() const override;
template<typename... Args> static ConvexCollider3DRef New(Args&&... args);
@@ -209,7 +209,7 @@ namespace Nz
float GetLength() const;
float GetRadius() const;
GeomType GetType() const override;
ColliderType3D GetType() const override;
template<typename... Args> static CylinderCollider3DRef New(Args&&... args);
@@ -233,7 +233,7 @@ namespace Nz
void ComputeInertialMatrix(Vector3f* inertia, Vector3f* center) const override;
GeomType GetType() const override;
ColliderType3D GetType() const override;
template<typename... Args> static NullCollider3DRef New(Args&&... args);
@@ -256,7 +256,7 @@ namespace Nz
float ComputeVolume() const override;
float GetRadius() const;
GeomType GetType() const override;
ColliderType3D GetType() const override;
template<typename... Args> static SphereCollider3DRef New(Args&&... args);

View File

@@ -4,24 +4,27 @@
#pragma once
#ifndef NAZARA_ENUMS_PHYSICS_HPP
#define NAZARA_ENUMS_PHYSICS_HPP
#ifndef NAZARA_ENUMS_PHYSICS3D_HPP
#define NAZARA_ENUMS_PHYSICS3D_HPP
enum GeomType
namespace Nz
{
GeomType_Box,
GeomType_Capsule,
GeomType_Cone,
GeomType_Compound,
GeomType_ConvexHull,
GeomType_Cylinder,
GeomType_Heightfield,
GeomType_Null,
GeomType_Scene,
GeomType_Sphere,
GeomType_Tree,
enum ColliderType3D
{
ColliderType3D_Box,
ColliderType3D_Capsule,
ColliderType3D_Cone,
ColliderType3D_Compound,
ColliderType3D_ConvexHull,
ColliderType3D_Cylinder,
ColliderType3D_Heightfield,
ColliderType3D_Null,
ColliderType3D_Scene,
ColliderType3D_Sphere,
ColliderType3D_Tree,
GeomType_Max = GeomType_Tree
ColliderType3D_Max = ColliderType3D_Tree
};
};
#endif // NAZARA_ENUMS_PHYSICS_HPP
#endif // NAZARA_ENUMS_PHYSICS3D_HPP