mirror of
https://git.intern.spaceteamaachen.de/ALPAKA/sta-peak.git
synced 2025-06-12 19:05:58 +00:00
38 lines
629 B
C++
38 lines
629 B
C++
/*
|
|
* quaternion.hpp
|
|
*
|
|
* Created on: Jun 17, 2024
|
|
* Author: Dario
|
|
*/
|
|
|
|
#ifndef STA_PEAK_QUATERNION_HPP
|
|
#define STA_PEAK_QUATERNION_HPP
|
|
|
|
namespace sta
|
|
{
|
|
namespace math {
|
|
class Quaternion
|
|
{
|
|
public:
|
|
Quaternion(float w, float x, float y, float z);
|
|
|
|
Quaternion();
|
|
|
|
Quaternion integrate(float dt, float ox, float oy, float oz);
|
|
|
|
static Quaternion unit();
|
|
|
|
float norm();
|
|
|
|
Quaternion normalized();
|
|
|
|
Quaternion operator+(const Quaternion& quat);
|
|
Quaternion operator*(float scalar);
|
|
public:
|
|
float x, y, z, w;
|
|
};
|
|
} // namespace math
|
|
} // namespace sta
|
|
|
|
#endif /* STA_PEAK_QUATERNION_HPP */
|