|
BIMHome v1.0.0
BIMHome接口文档说明
|
#include <Rotation.h>
Public 类型 | |
| enum | EulerSequence { Invalid , EulerAngles , YawPitchRoll , Extrinsic_XYZ , Extrinsic_XZY , Extrinsic_YZX , Extrinsic_YXZ , Extrinsic_ZXY , Extrinsic_ZYX , Intrinsic_XYZ , Intrinsic_XZY , Intrinsic_YZX , Intrinsic_YXZ , Intrinsic_ZXY , Intrinsic_ZYX , Extrinsic_XYX , Extrinsic_XZX , Extrinsic_YZY , Extrinsic_YXY , Extrinsic_ZYZ , Extrinsic_ZXZ , Intrinsic_XYX , Intrinsic_XZX , Intrinsic_YZY , Intrinsic_YXY , Intrinsic_ZXZ , Intrinsic_ZYZ , EulerSequenceLast } |
| 欧拉角序列枚举 更多... | |
Public 成员函数 | |
| void | getEulerAngles (EulerSequence seq, double &alpha, double &beta, double &gamma) const |
| 从旋转矩阵中提取欧拉角 | |
| void | getRawValue (Vector3d &axis, double &rfAngle) const |
| 获取当前对象的旋转轴和旋转角度,不进行归一化 | |
| const double * | getValue () const |
| 获取当前对象的四元数分量 | |
| void | getValue (double &q0, double &q1, double &q2, double &q3) const |
| 获取当前对象的四元数分量 | |
| void | getValue (Matrix4D &matrix) const |
| 将四元数表示的旋转转换为 4x4 矩阵表示 | |
| void | getValue (Vector3d &axis, double &rfAngle) const |
| 获取当前对象的旋转轴和旋转角度 | |
| void | getYawPitchRoll (double &y, double &p, double &r) const |
| 从四元数中提取偏航(yaw)、俯仰(pitch)、翻滚(roll)这三个欧拉角 | |
| Rotation | inverse () const |
| 返回当前旋转对象的逆旋转 | |
| Rotation & | invert () |
| 求取当前旋转对象的逆旋转 | |
| bool | isIdentity () const |
| 检查当前旋转对象是否表示一个单位(或恒等)旋转 | |
| bool | isNull () const |
| 检查当前旋转对象是否表示一个“空”的旋转 | |
| bool | isSame (const Rotation &q) const |
| 检查当前旋转对象是否与另一个旋转对象 q 相同,或者是否是彼此的逆 | |
| bool | isSame (const Rotation &q, double tol) const |
| 检查当前旋转对象是否在指定的公差范围内与另一个旋转对象 q 相同或者互为逆 | |
| Vector3d | multVec (const Vector3d &src) const |
| 将四元数表示的旋转应用于一个三维向量,并返回旋转后的向量 | |
| void | multVec (const Vector3d &src, Vector3d &dst) const |
| 将四元数表示的旋转应用于一个三维向量 | |
| bool | operator!= (const Rotation &q) const |
| 比较两个旋转对象是否不相等 | |
| Rotation | operator* (const Rotation &q) const |
| 组合当前旋转对象与另一个旋转对象 q 的旋转 | |
| Rotation & | operator*= (const Rotation &q) |
| 当前旋转对象与另一个旋转对象相乘,并将结果存储在当前对象中,从而组合这两个旋转 | |
| void | operator= (const Rotation &rot) |
| 将一个 Rotation 对象的状态赋值给另一个 Rotation 对象 | |
| bool | operator== (const Rotation &q) const |
| 比较两个旋转对象是否相等 | |
| double & | operator[] (unsigned short usIndex) |
| 允许像访问数组元素一样访问 Rotation 类的四元数成员变量 m_Quat 的元素 | |
| const double & | operator[] (unsigned short usIndex) const |
| 允许以只读方式访问四元数成员变量 m_Quat 的元素 | |
| Rotation () | |
| 默认构造函数,初始化了一个表示没有旋转的 Rotation 对象 | |
| Rotation (const double q0, const double q1, const double q2, const double q3) | |
| 根据给定的四元数分量创建一个 Rotation 对象 | |
| Rotation (const double q[4]) | |
| 根据给定的四元数分量创建一个 Rotation 对象 | |
| Rotation (const Matrix4D &matrix) | |
| 从一个 4x4 变换矩阵中提取旋转部分,并创建一个 Rotation 对象 | |
| Rotation (const Rotation &rot) | |
| 拷贝构造函数 | |
| Rotation (const Vector3d &axis, const double fAngle) | |
| 创建一个围绕给定轴旋转指定角度的 Rotation 对象 | |
| Rotation (const Vector3d &rotateFrom, const Vector3d &rotateTo) | |
| 创建一个 Rotation 对象,该对象表示从 rotateFrom 向量旋转到 rotateTo 向量所需的旋转 | |
| void | scaleAngle (const double scaleFactor) |
| 按给定的缩放因子调整旋转角度 | |
| void | setEulerAngles (EulerSequence seq, double alpha, double beta, double gamma) |
| 根据指定的欧拉角顺序和角度值来设置旋转对象的状态 | |
| void | setValue (const double q0, const double q1, const double q2, const double q3) |
| 设置 Rotation 对象的四元数分量,并进行归一化和向量评估 | |
| void | setValue (const double q[4]) |
| 通过一个四元数数组来设置旋转对象的值 | |
| void | setValue (const Matrix4D &matrix) |
| 从 4x4 矩阵中提取旋转分量,并将其转换为四元数表示 | |
| void | setValue (const Vector3d &axis, const double fAngle) |
| 根据给定的旋转轴和旋转角度来设置四元数 | |
| void | setValue (const Vector3d &rotateFrom, const Vector3d &rotateTo) |
| 根据两个三维向量 rotateFrom 和 rotateTo 来设置旋转 | |
| void | setYawPitchRoll (double y, double p, double r) |
| 根据偏航(yaw)、俯仰(pitch)、翻滚(roll)这三个欧拉角设置 Rotation 对象的四元数 | |
静态 Public 成员函数 | |
| static EulerSequence | eulerSequenceFromName (const char *name) |
| 根据指定的字符串名称返回对应的欧拉角序列枚举值 | |
| static const char * | eulerSequenceName (EulerSequence seq) |
| 根据传入的 EulerSequence 枚举值返回对应的字符串名称 | |
| static Rotation | identity () |
| 创建一个表示恒等旋转的 Rotation 对象 | |
| static Rotation | makeRotationByAxes (Vector3d xdir, Vector3d ydir, Vector3d zdir, const char *priorityOrder="ZXY") |
| 创建一个旋转,将以 xdir、ydir 和 zdir 为轴的本地坐标系中的向量转换为全局坐标系中的向量 | |
| static Rotation | slerp (const Rotation &rot0, const Rotation &rot1, double t) |
| 执行两个四元数之间的球面线性插值(Spherical Linear Interpolation,简称 SLERP) | |
Private 成员函数 | |
| void | evaluateVector () |
| 用于从四元数表示的旋转中计算出对应的轴角表示 | |
| void | normalize () |
| 归一化当前旋转对象的四元数 | |
Private 属性 | |
| double | m_Angle |
| 旋转角度 | |
| Vector3d | m_Axis |
| 旋转轴 | |
| double | m_Quat [4] |
| 四元数分量 | |