|
Vulkan Schnee 0.0.1
High-performance rendering engine
|
#include <OpenXrHelper.h>
Classes | |
| struct | posef |
| A glm based posef struct. More... | |
Public Types | |
| typedef struct EngineCore::OpenXrHelper::posef | posef |
| A glm based posef struct. | |
Static Public Member Functions | |
| template<typename T> | |
| static void | LoadXrFunction (XrInstance xrInstance, const std::string &functionName, T &functionPointer) |
| Loads a function from openxr which is not loaded at compile time. Retrieves function pointer. | |
| static XrPosef | makeIdentityPose () |
| Makes identity pose. | |
| static glm::mat4 | poseToMatrix (const XrPosef &pose) |
| Converts an XrPosef to a glm::mat4. | |
| static glm::mat4 | poseToMatrix (const OpenXrHelper::posef &pose) |
| Pose of glm components to glm::mat4. | |
| static glm::quat | xrQuaternionfToGlmQuat (const XrQuaternionf &xrQuaternion) |
| Turns the OpenXR quaternion into an OpenXR quaternion. | |
| static XrQuaternionf | glmQuatToXrQuaternionf (const glm::quat &glmQuaternion) |
| Glm quaternion to xr quaternionf. | |
| static glm::vec3 | xrVector3fToGlmVec3 (const XrVector3f &xrVector3) |
| Converts an OpenXR vector3 to a glm vector3. | |
| static XrVector3f | glmVec3ToXrVector3f (const glm::vec3 &glmVector3) |
| Converts a glm::vec3 to a XrVector3f. | |
| static float | dot (const glm::quat &a, const glm::quat &b) |
| Calculates the dot product between two glm quaternions. | |
| static glm::quat | lerpMix (const glm::quat &from, const glm::quat &to, float progress) |
| Linearly interpolate between two quaternions. | |
| static glm::vec3 | lerpMix (const glm::vec3 &from, const glm::vec3 &to, float progress) |
| Linearly interpolate between two glm vector3's. | |
| static float | lerpMix (float from, float to, float progress) |
| Linearly interpolate between two float values. | |
| static float | dot (const glm::vec3 &a, const glm::vec3 &b) |
| The dot product between two glm vector3's. | |
| static glm::vec3 | crossProductVector3 (const glm::vec3 &vector_a, const glm::vec3 &vector_b) |
| static float | clampf (float num, float left, float right) |
| static float | lengthSquared (const glm::vec3 &vec) |
| static float | length (const glm::vec3 &vec) |
| static glm::vec3 | normalize (const glm::vec3 &vec) |
| static float | distanceSquared (const glm::vec3 &vec1, const glm::vec3 &vec2) |
| static float | distance (const glm::vec3 &vec1, const glm::vec3 &vec2) |
| static glm::quat | slerp (const glm::quat &start, const glm::quat &end, float percent) |
| static glm::vec3 | slerp (const glm::vec3 &start, const glm::vec3 &end, float percent) |
| static float | vectorAngleAroundNormal (const glm::vec3 &vec1, const glm::vec3 &vec2, const glm::vec3 &norm) |
| static glm::mat4 | rotationAroundPoint (glm::vec3 point, glm::mat4 rotationMatrix) |
| static void | quaternionToAngleAxis (const glm::quat &quat, float &angle, glm::vec3 &axis) |
| static glm::quat | quaternionFromAngleAxis (const float &angle, const glm::vec3 &axis) |
| static posef | xrPosefToGlmPosef (const XrPosef &xrPosef) |
| static glm::mat4 | createProjectionMatrix (XrFovf fov, float nearClip, float farClip) |
| static std::string | sessionStateToString (XrSessionState state) |
| static const char * | GetXrStructureTypeName (XrStructureType type) |
Definition at line 11 of file OpenXrHelper.h.
| typedef struct EngineCore::OpenXrHelper::posef EngineCore::OpenXrHelper::posef |
A glm based posef struct.
|
static |
Definition at line 95 of file OpenXrHelper.cpp.
Referenced by slerp().
|
static |
Definition at line 218 of file OpenXrHelper.cpp.
Referenced by EngineCore::Headset::updateViewMatrix().
|
static |
Definition at line 87 of file OpenXrHelper.cpp.
|
static |
Definition at line 121 of file OpenXrHelper.cpp.
References distanceSquared().
|
static |
Definition at line 116 of file OpenXrHelper.cpp.
Referenced by distance().
|
static |
Calculates the dot product between two glm quaternions.
| a | A glm::quat to process. |
| b | A glm::quat to process. |
Definition at line 67 of file OpenXrHelper.cpp.
Referenced by slerp(), slerp(), and vectorAngleAroundNormal().
|
static |
The dot product between two glm vector3's.
| a | A glm::vec3 to process. |
| b | A glm::vec3 to process. |
Definition at line 83 of file OpenXrHelper.cpp.
|
static |
Definition at line 255 of file OpenXrHelper.cpp.
Referenced by EngineCore::Headset::waitForXrFrame().
|
static |
Glm quaternion to xr quaternionf.
| glmQuaternion | Source for the. |
Definition at line 38 of file OpenXrHelper.cpp.
|
static |
Converts a glm::vec3 to a XrVector3f.
| glmVector3 | the glm vector3 to convert. |
Definition at line 51 of file OpenXrHelper.cpp.
|
static |
Definition at line 107 of file OpenXrHelper.cpp.
References lengthSquared().
Referenced by normalize().
|
static |
Definition at line 103 of file OpenXrHelper.cpp.
Referenced by length().
|
static |
Linearly interpolate between two quaternions.
| from | The start quaternion. |
| to | the target quaternion. |
| progress | A float to process. |
Definition at line 59 of file OpenXrHelper.cpp.
|
static |
Linearly interpolate between two glm vector3's.
| from | The vector3 to interpolate from. |
| to | The vector3 to interpolate to. |
| progress | The factor of how close return is to the target. |
Definition at line 71 of file OpenXrHelper.cpp.
|
static |
Linearly interpolate between two float values.
| from | The float to interpolate from. |
| to | The float to interpolate to. |
| progress | The factor of how close return is to the target. 0.0f is from 1.0f is target. |
Definition at line 79 of file OpenXrHelper.cpp.
|
inlinestatic |
Loads a function from openxr which is not loaded at compile time. Retrieves function pointer.
| xrInstance | The instance. | |
| functionName | Name of the function. | |
| [out] | functionPointer | The function pointer. |
| std::runtime_error | Raised when the requested function was not found. |
| T | The class of the function pointer. |
Definition at line 37 of file OpenXrHelper.h.
Referenced by EngineCore::ApplicationContext::createDevice(), and EngineCore::ApplicationContext::LoadOpenXrExtensionFunctions().
|
static |
Makes identity pose.
Definition at line 8 of file OpenXrHelper.cpp.
Referenced by EngineCore::Headset::Headset().
|
static |
Definition at line 111 of file OpenXrHelper.cpp.
References length().
Referenced by slerp().
|
static |
Pose of glm components to glm::mat4.
| pose | The pose. |
Definition at line 23 of file OpenXrHelper.cpp.
References EngineCore::OpenXrHelper::posef::orientation, and EngineCore::OpenXrHelper::posef::position.
|
static |
Converts an XrPosef to a glm::mat4.
| pose | The pose XrPose. |
Definition at line 16 of file OpenXrHelper.cpp.
Referenced by Input::XrInputHandler::syncInputs(), and EngineCore::Headset::updateViewMatrix().
|
static |
Definition at line 197 of file OpenXrHelper.cpp.
|
static |
Definition at line 188 of file OpenXrHelper.cpp.
|
static |
Definition at line 179 of file OpenXrHelper.cpp.
|
static |
Definition at line 237 of file OpenXrHelper.cpp.
Referenced by EngineCore::Headset::waitForXrFrame().
|
static |
Definition at line 126 of file OpenXrHelper.cpp.
References dot().
|
static |
Definition at line 148 of file OpenXrHelper.cpp.
References clampf(), dot(), and normalize().
|
static |
Definition at line 172 of file OpenXrHelper.cpp.
References dot().
|
static |
Definition at line 209 of file OpenXrHelper.cpp.
References xrQuaternionfToGlmQuat(), and xrVector3fToGlmVec3().
Referenced by Input::XrInputHandler::syncInputs().
|
static |
Turns the OpenXR quaternion into an OpenXR quaternion.
| xrQuaternion | Source for the. |
Definition at line 34 of file OpenXrHelper.cpp.
Referenced by xrPosefToGlmPosef().
|
static |
Converts an OpenXR vector3 to a glm vector3.
| xrVector3 | OpenXR vector3 to convert. |
Definition at line 47 of file OpenXrHelper.cpp.
Referenced by xrPosefToGlmPosef().