|
| Quaternion () |
| Constructs a quaternion representing the identity rotation (w = 1, 0, 0, 0).
|
|
template<typename S , int Options> |
| Quaternion (const Eigen::Quaternion< S, Options > &q) |
|
| Quaternion (const Scalar &angle, const Point3< Scalar > &axis) |
|
| Quaternion (const Matrix44< Scalar > &rotMatrix) |
|
| Quaternion (const Point3< Scalar > &a, const Point3< Scalar > &b) |
| Constructs the quaternion that will represent the rotation between the two arbitrary vectors a and b.
|
|
template<typename S > |
auto | cast () const |
| Casts the Quaternion object to a different scalar type.
|
|
constexpr uint | size () const |
|
void | set (const Scalar &w, const Scalar &x, const Scalar &y, const Scalar &z) |
|
void | setFromAngleAxis (const Scalar &angle, const Point3< Scalar > &axis) |
|
std::size_t | hash () const |
| Computes the hash value of the quaternion.
|
|
Point3< Scalar > | operator* (const Point3< Scalar > &p) const |
| Quaternion-Vector multiplication.
|
|
template<
typename Scalar>
class vcl::Quaternion< Scalar >
Quaternion class.
This class represents a quaternion, w + xi + yj + zk
vector with a scalar part and a vector part.
Note that the scalar part is stored in the w
component, while the vector part is stored in the x
, y
and z
components.
- Note
- Note that internally the coefficients are stored in the following order: [x, y, z, w]. This means that accessing to the first component of the quaternion (index 0) will return the
x
component, and the last component (index 3) will return the w
component.
- Template Parameters
-
Scalar | the scalar used to represent the quaternion. |