Vulkan Schnee 0.0.1
High-performance rendering engine
Loading...
Searching...
No Matches
XrRig.h
Go to the documentation of this file.
1#pragma once
2
4
5#include <glm/glm.hpp>
6#include <glm/gtc/quaternion.hpp>
7
8#include <cstddef>
9
10namespace Engine::Rendering
11{
12 class Headset;
13}
14
15namespace Input
16{
18 {
19 bool isValid = false;
20 glm::vec3 position{ 0.0f };
21 glm::quat orientation{ 1.0f, 0.0f, 0.0f, 0.0f };
22 };
23
28 class XrRig
29 {
30 public:
31 XrRig( const XrInputHandler * inputHandler, const Engine::Rendering::Headset * headset );
32
34
35 [[nodiscard]] TrackedHandPose getHandPose( Hand hand ) const;
36
37 private:
38 const XrInputHandler * inputHandler_ = nullptr;
41 };
42} // namespace Input
Handles OpenXR input actions and controller state.
TrackedHandPose getHandPose(Hand hand) const
const XrInputHandler * inputHandler_
Definition XrRig.h:38
void resolveTrackedPoses()
TrackedHandPose handPoses_[2]
Definition XrRig.h:40
const Engine::Rendering::Headset * headset_
Definition XrRig.h:39
XrRig(const XrInputHandler *inputHandler, const Engine::Rendering::Headset *headset)
glm::quat orientation
Definition XrRig.h:21
glm::vec3 position
Definition XrRig.h:20