Frame Functions¶
Functions to compute coordinate frames.
#include <Imath/ImathFrame.h>
-
template<class
T
>
constexpr Matrix44<T>Imath
::
firstFrame
(const Vec3<T> &pi, const Vec3<T> &pj, const Vec3<T> &pk) noexcept¶ Compute the first reference frame along a curve.
This function returns the transformation matrix to the reference frame defined by the three points
pi
,pj
andpk
. Note that if the two vectors <pi
,pj
> and <pi
,pk
> are colinears, an arbitrary twist value will be choosen.Throw
std::domain_error
ifpi
andpj
are equal.- Parameters
pi
: First pointpj
: Second pointpk
: Third point
-
template<class
T
>
constexpr Matrix44<T>Imath
::
nextFrame
(const Matrix44<T> &Mi, const Vec3<T> &pi, const Vec3<T> &pj, Vec3<T> &ti, Vec3<T> &tj) noexcept¶ Compute the next reference frame along a curve.
This function returns the transformation matrix to the next reference frame defined by the previously computed transformation matrix and the new point and tangent vector along the curve.
- Parameters
Mi
: The previous matrixpi
: The previous pointpj
: The current pointti
: The previous tangent vectortj
: The current tangent vector
-
template<class
T
>
constexpr Matrix44<T>Imath
::
lastFrame
(const Matrix44<T> &Mi, const Vec3<T> &pi, const Vec3<T> &pj) noexcept¶ Compute the last reference frame along a curve.
This function returns the transformation matrix to the last reference frame defined by the previously computed transformation matrix and the last point along the curve.
- Parameters
Mi
: The previous matrixpi
: The previous pointpj
: The last point