A vectorization friendly 3D vector. More...
Public Types | |
|
typedef MatrixBase < AlignedVector3< _Scalar > > | Base |
Public Member Functions | |
| AlignedVector3 (const Scalar &x, const Scalar &y, const Scalar &z) | |
| AlignedVector3 (const AlignedVector3 &other) | |
| template<typename Derived > | |
| AlignedVector3 (const MatrixBase< Derived > &other) | |
| const Scalar & | coeff (Index row, Index col) const |
| const Scalar & | coeff (Index index) const |
| Scalar & | coeffRef (Index row, Index col) |
| Scalar & | coeffRef (Index index) |
| Index | cols () const |
| AlignedVector3 | cross (const AlignedVector3 &other) const |
| Scalar | dot (const AlignedVector3 &other) const |
| template<typename Derived > | |
| bool | isApprox (const MatrixBase< Derived > &other, RealScalar eps=NumTraits< Scalar >::dummy_precision()) const |
| Scalar | norm () const |
| void | normalize () |
| AlignedVector3 | normalized () |
| AlignedVector3 | operator* (const Scalar &s) const |
| AlignedVector3 & | operator*= (const Scalar &s) |
| AlignedVector3 | operator+ (const AlignedVector3 &other) const |
| AlignedVector3 & | operator+= (const AlignedVector3 &other) |
| AlignedVector3 | operator- (const AlignedVector3 &other) const |
| AlignedVector3 | operator-= (const AlignedVector3 &other) |
| AlignedVector3 | operator/ (const Scalar &s) const |
| AlignedVector3 & | operator/= (const Scalar &s) |
| AlignedVector3 & | operator= (const AlignedVector3 &other) |
| Index | rows () const |
| Scalar | squaredNorm () const |
| Scalar | sum () const |
Friends | |
| AlignedVector3 | operator* (const Scalar &s, const AlignedVector3 &vec) |
A vectorization friendly 3D vector.
This class represents a 3D vector internally using a 4D vector such that vectorization can be seamlessly enabled. Of course, the same result can be achieved by directly using a 4D vector. This class makes this process simpler.
1.8.1.1