|
Engine²
Open-source game engine written in C++.
|
Namespaces | |
| namespace | BroadPhaseLayers |
| namespace | Layers |
Classes | |
| class | BiMap |
| class | BPLayerInterfaceImpl |
| class | ContactCallback |
| class | ContactListenerImpl |
| ContactListener implementation. More... | |
| class | ObjectLayerPairFilterImpl |
| class | ObjectVsBroadPhaseLayerFilterImpl |
Typedefs | |
| using | BaseCallback = FunctionUtils::BaseFunction<void, Engine::Core &, Engine::Entity &, Engine::Entity &> |
| A utility class for handling contact callbacks in a physics engine. | |
Functions | |
| JPH::Vec3 | ToJoltVec3 (const glm::vec3 &v) |
| Convert glm::vec3 to JPH::Vec3. | |
| JPH::RVec3 | ToJoltRVec3 (const glm::vec3 &v) |
| Convert glm::vec3 to JPH::RVec3 (real vector, double precision). | |
| JPH::Quat | ToJoltQuat (const glm::quat &q) |
| Convert glm::quat to JPH::Quat. | |
| glm::vec3 | FromJoltVec3 (const JPH::Vec3 &v) |
| Convert JPH::Vec3 to glm::vec3. | |
| glm::vec3 | FromJoltRVec3 (const JPH::RVec3 &v) |
| Convert JPH::RVec3 (real vector, double precision) to glm::vec3. | |
| glm::quat | FromJoltQuat (const JPH::Quat &q) |
| Convert JPH::Quat to glm::quat. | |
Variables | |
| static constexpr const uint32_t | ENTITY_ID_MASK |
| using Physics::Utils::BaseCallback = FunctionUtils::BaseFunction<void, Engine::Core &, Engine::Entity &, Engine::Entity &> |
A utility class for handling contact callbacks in a physics engine.
| Components | The components to check for in the entities involved in the contact. |
|
inline |
Convert JPH::Quat to glm::quat.
|
inline |
Convert JPH::RVec3 (real vector, double precision) to glm::vec3.
|
inline |
Convert JPH::Vec3 to glm::vec3.
|
inline |
Convert glm::quat to JPH::Quat.
|
inline |
Convert glm::vec3 to JPH::RVec3 (real vector, double precision).
|
inline |
Convert glm::vec3 to JPH::Vec3.
|
inlinestaticconstexpr |
EnTT divides the entity ID into two parts: the entity index and the version. The entity index is the index of the entity in the registry, and the version part is a counter that increments every time an entity with the same index is destroyed and recreated. When recreating an entity from an integer, we need to make sure that both parts are preserved.
With 32 bits the value of ENTITY_ID_MASK will be 0xFFFFFFFF.
Note: we have to shift the entity mask to the left by the number of bits it has, which means we have to compute the size of the type in bits (sizeof(type) * 8), substract the number of bits used by the entity mask (we get it using popcount) and then shift the entity mask to the left by that number of bits.