diff options
Diffstat (limited to 'src/core/frontend')
| -rw-r--r-- | src/core/frontend/input.h | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/core/frontend/input.h b/src/core/frontend/input.h index 88ebc6497..0c5d2b3b0 100644 --- a/src/core/frontend/input.h +++ b/src/core/frontend/input.h | |||
| @@ -11,6 +11,7 @@ | |||
| 11 | #include <utility> | 11 | #include <utility> |
| 12 | #include "common/logging/log.h" | 12 | #include "common/logging/log.h" |
| 13 | #include "common/param_package.h" | 13 | #include "common/param_package.h" |
| 14 | #include "common/quaternion.h" | ||
| 14 | #include "common/vector_math.h" | 15 | #include "common/vector_math.h" |
| 15 | 16 | ||
| 16 | namespace Input { | 17 | namespace Input { |
| @@ -143,9 +144,10 @@ using VibrationDevice = InputDevice<u8>; | |||
| 143 | 144 | ||
| 144 | /** | 145 | /** |
| 145 | * A motion status is an object that returns a tuple of accelerometer state vector, | 146 | * A motion status is an object that returns a tuple of accelerometer state vector, |
| 146 | * gyroscope state vector, rotation state vector and orientation state matrix. | 147 | * gyroscope state vector, rotation state vector, orientation state matrix and quaterion state |
| 148 | * vector. | ||
| 147 | * | 149 | * |
| 148 | * For both vectors: | 150 | * For both 3D vectors: |
| 149 | * x+ is the same direction as RIGHT on D-pad. | 151 | * x+ is the same direction as RIGHT on D-pad. |
| 150 | * y+ is normal to the touch screen, pointing outward. | 152 | * y+ is normal to the touch screen, pointing outward. |
| 151 | * z+ is the same direction as UP on D-pad. | 153 | * z+ is the same direction as UP on D-pad. |
| @@ -164,9 +166,13 @@ using VibrationDevice = InputDevice<u8>; | |||
| 164 | * x vector | 166 | * x vector |
| 165 | * y vector | 167 | * y vector |
| 166 | * z vector | 168 | * z vector |
| 169 | * | ||
| 170 | * For quaternion state vector | ||
| 171 | * xyz vector | ||
| 172 | * w float | ||
| 167 | */ | 173 | */ |
| 168 | using MotionStatus = std::tuple<Common::Vec3<float>, Common::Vec3<float>, Common::Vec3<float>, | 174 | using MotionStatus = std::tuple<Common::Vec3<float>, Common::Vec3<float>, Common::Vec3<float>, |
| 169 | std::array<Common::Vec3f, 3>>; | 175 | std::array<Common::Vec3f, 3>, Common::Quaternion<f32>>; |
| 170 | 176 | ||
| 171 | /** | 177 | /** |
| 172 | * A motion device is an input device that returns a motion status object | 178 | * A motion device is an input device that returns a motion status object |