quaternion: add matrix multiply convenience method
This commit is contained in:
parent
eb2b85c4f6
commit
999ec1c35c
@ -152,6 +152,24 @@ namespace util {
|
||||
}
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
template <typename T>
|
||||
matrix<4,4,T>
|
||||
operator* (quaternion<T> q, matrix<4,4,T> m)
|
||||
{
|
||||
return q.as_matrix () * m;
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------
|
||||
template <typename T>
|
||||
matrix<4,4,T>
|
||||
operator* (matrix<4,4,T> m, quaternion<T> q)
|
||||
{
|
||||
return m * q.as_matrix ();
|
||||
}
|
||||
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
template <typename T>
|
||||
constexpr
|
||||
|
Loading…
Reference in New Issue
Block a user