|
ACTS
Experiment-independent tracking
|
Transform wrapper class to ensure standard API within different plugins. More...
#include <algebra/impl/eigen_transform3.hpp>
Public Types | |
Type definitions for the struct | |
| using | scalar_type = scalar_t |
| Scalar type used by the transform. | |
| template<int N> | |
| using | array_type = eigen::array<scalar_type, N> |
| Array type used by the transform. | |
| using | vector2 = array_type<2> |
| Vector and point types. | |
| using | vector3 = array_type<3> |
| Three-component vector type used for spatial quantities. | |
| using | point2 = vector2 |
| Two-dimensional point representation. | |
| using | point3 = vector3 |
| Three-dimensional point representation. | |
| using | matrix44 |
| 4x4 matrix type | |
| template<concepts::scalar o_scalar_t> | |
| using | other_type = transform3<o_scalar_t> |
| Helper type to cast this to another floating point precision. | |
Public Member Functions | |
| transform3 () | |
| Default constructor: set contents to identity matrices. | |
| transform3 (const array_type< 16 > &ma) | |
| Constructor with arguments: matrix as std::array of scalar. | |
| transform3 (const matrix44 &m) | |
| Constructor with arguments: matrix. | |
| transform3 (const matrix44 &m, const matrix44 &m_inv) | |
| Constructor with arguments: matrix and its inverse. | |
| transform3 (const transform3 &rhs)=default | |
| Copy an existing transform. | |
| transform3 (const vector3 &t) | |
| Constructor with arguments: translation. | |
| transform3 (const vector3 &t, const vector3 &x, const vector3 &y, const vector3 &z, bool get_inverse=true) | |
| Constructor with arguments: t, x, y, z. | |
| transform3 (const vector3 &t, const vector3 &z, const vector3 &x, bool get_inverse=true) | |
| Constructor with arguments: t, z, x. | |
| constexpr const matrix44 & | matrix () const |
| This method retrieves the 4x4 matrix of a transform. | |
| constexpr const matrix44 & | matrix_inverse () const |
| This method retrieves the 4x4 matrix of an inverse transform. | |
| constexpr bool | operator== (const transform3 &rhs) const |
| Equality operator. | |
| template<typename derived_type> requires (Eigen::MatrixBase<derived_type>::RowsAtCompileTime == 3 && Eigen::MatrixBase<derived_type>::ColsAtCompileTime == 1) | |
| constexpr auto | point_to_global (const Eigen::MatrixBase< derived_type > &v) const |
| This method transform from a point from the local 3D cartesian frame to the global 3D cartesian frame. | |
| template<typename derived_type> requires (Eigen::MatrixBase<derived_type>::RowsAtCompileTime == 2 && Eigen::MatrixBase<derived_type>::ColsAtCompileTime == 1) | |
| constexpr auto | point_to_global (const Eigen::MatrixBase< derived_type > &v) const |
| This method transform from a point from the local 2D cartesian frame to the global 3D cartesian frame. | |
| template<typename derived_type> requires (Eigen::MatrixBase<derived_type>::RowsAtCompileTime == 3 && Eigen::MatrixBase<derived_type>::ColsAtCompileTime == 1) | |
| constexpr auto | point_to_local (const Eigen::MatrixBase< derived_type > &v) const |
| This method transform from a vector from the global 3D cartesian frame into the local 3D cartesian frame. | |
| constexpr auto | rotation () const |
| This method retrieves the rotation of a transform. | |
| constexpr point3 | translation () const |
| This method retrieves the translation of a transform. | |
| template<typename derived_type> requires (Eigen::MatrixBase<derived_type>::RowsAtCompileTime == 3 && Eigen::MatrixBase<derived_type>::ColsAtCompileTime == 1) | |
| constexpr auto | vector_to_global (const Eigen::MatrixBase< derived_type > &v) const |
| This method transform from a vector from the local 3D cartesian frame to the global 3D cartesian frame. | |
| template<typename derived_type> requires (Eigen::MatrixBase<derived_type>::RowsAtCompileTime == 2 && Eigen::MatrixBase<derived_type>::ColsAtCompileTime == 1) | |
| constexpr auto | vector_to_global (const Eigen::MatrixBase< derived_type > &v) const |
| This method transform from a vector from the local 3D cartesian frame to the global 3D cartesian frame. | |
| template<typename derived_type> requires (Eigen::MatrixBase<derived_type>::RowsAtCompileTime == 3 && Eigen::MatrixBase<derived_type>::ColsAtCompileTime == 1) | |
| constexpr auto | vector_to_local (const Eigen::MatrixBase< derived_type > &v) const |
| This method transform from a vector from the global 3D cartesian frame into the local 3D cartesian frame. | |
| constexpr point3 | x () const |
| This method retrieves x axis. | |
| constexpr point3 | y () const |
| This method retrieves y axis. | |
| constexpr point3 | z () const |
| This method retrieves z axis. | |
Static Public Member Functions | |
| template<typename derived_type> requires (Eigen::MatrixBase<derived_type>::RowsAtCompileTime == 3 && Eigen::MatrixBase<derived_type>::ColsAtCompileTime == 1) | |
| static constexpr auto | rotate (const Eigen::Transform< scalar_type, 3, Eigen::Affine > &m, const Eigen::MatrixBase< derived_type > &v) |
| Rotate a vector into / from a frame. | |
| template<typename derived_type> requires (Eigen::MatrixBase<derived_type>::RowsAtCompileTime == 2 && Eigen::MatrixBase<derived_type>::ColsAtCompileTime == 1) | |
| static constexpr auto | rotate (const Eigen::Transform< scalar_type, 3, Eigen::Affine > &m, const Eigen::MatrixBase< derived_type > &v) |
| Rotate a vector into / from a frame. | |
Public Attributes | |
Data objects | |
| Eigen::Transform< scalar_type, 3, Eigen::Affine > | _data |
| Local-to-global affine transformation. | |
| Eigen::Transform< scalar_type, 3, Eigen::Affine > | _data_inv |
| Global-to-local affine transformation. | |
Transform wrapper class to ensure standard API within different plugins.
| using detray::algebra::eigen::math::transform3< scalar_t >::matrix44 |
4x4 matrix type
| detray::algebra::eigen::math::transform3< scalar_t >::transform3 | ( | const vector3 & | t, |
| const vector3 & | x, | ||
| const vector3 & | y, | ||
| const vector3 & | z, | ||
| bool | get_inverse = true ) |
Constructor with arguments: t, x, y, z.
| t | the translation (or origin of the new frame) |
| x | the x axis of the new frame |
| y | the y axis of the new frame |
| z | the z axis of the new frame, normal vector for planes |
| get_inverse | whether to compute and store the inverse |
| detray::algebra::eigen::math::transform3< scalar_t >::transform3 | ( | const vector3 & | t, |
| const vector3 & | z, | ||
| const vector3 & | x, | ||
| bool | get_inverse = true ) |
Constructor with arguments: t, z, x.
| t | the translation (or origin of the new frame) |
| z | the z axis of the new frame, normal vector for planes |
| x | the x axis of the new frame |
| get_inverse | whether to compute and store the inverse |
|
explicit |
Constructor with arguments: translation.
| t | is the transform |
|
explicit |
Constructor with arguments: matrix.
| m | is the full 4x4 matrix |
| detray::algebra::eigen::math::transform3< scalar_t >::transform3 | ( | const matrix44 & | m, |
| const matrix44 & | m_inv ) |
Constructor with arguments: matrix and its inverse.
| m | is the full 4x4 matrix |
| m_inv | is the inverse to m |
|
explicit |
Constructor with arguments: matrix as std::array of scalar.
| ma | is the full 4x4 matrix as a 16 array |
|
default |
Copy an existing transform.
| rhs | Transform whose matrices are copied. |
|
constexpr |
This method retrieves the 4x4 matrix of a transform.
|
constexpr |
This method retrieves the 4x4 matrix of an inverse transform.
|
constexpr |
Equality operator.
| rhs | transform to compare with |
|
constexpr |
This method transform from a point from the local 3D cartesian frame to the global 3D cartesian frame.
| v | point in local coordinates |
|
constexpr |
This method transform from a point from the local 2D cartesian frame to the global 3D cartesian frame.
| v | point in local plane coordinates |
|
constexpr |
This method transform from a vector from the global 3D cartesian frame into the local 3D cartesian frame.
| v | vector in global coordinates |
|
staticconstexpr |
Rotate a vector into / from a frame.
| m | is the rotation matrix |
| v | is the vector to be rotated |
|
staticconstexpr |
Rotate a vector into / from a frame.
| m | is the rotation matrix |
| v | is the vector to be rotated |
|
constexpr |
This method retrieves the rotation of a transform.
|
constexpr |
This method retrieves the translation of a transform.
|
constexpr |
This method transform from a vector from the local 3D cartesian frame to the global 3D cartesian frame.
| v | vector in local coordinates |
|
constexpr |
This method transform from a vector from the local 3D cartesian frame to the global 3D cartesian frame.
| v | vector in local coordinates |
|
constexpr |
This method transform from a vector from the global 3D cartesian frame into the local 3D cartesian frame.
| v | vector in global coordinates |
|
constexpr |
This method retrieves x axis.
|
constexpr |
This method retrieves y axis.
|
constexpr |
This method retrieves z axis.