#ifndef OPENMW_COMPONENTS_ESM_QUATERNION_H #define OPENMW_COMPONENTS_ESM_QUATERNION_H #include namespace ESM { // format 0, savegames only struct Quaternion { float mValues[4]; Quaternion() = default; Quaternion(const osg::Quat& q) : mValues{ static_cast(q.w()), static_cast(q.x()), static_cast(q.y()), static_cast(q.z()), } { } operator osg::Quat() const { return osg::Quat(mValues[1], mValues[2], mValues[3], mValues[0]); } }; } #endif