35#include "foundation/PxTransform.h"
36#include "foundation/PxMat33.h"
59 : m(b0, b1, b2), p(b3)
65 m(values), p(values[9], values[10], values[11])
83 : m(other.q), p(other.p)
111 return m == other.m && p == other.p;
129 return PxMat34T(m + other.m, p + other.p);
135 return PxMat34T(m - other.m, p - other.p);
141 return PxMat34T(m*scalar, p*scalar);
149 return PxMat34T(m*other.m, m*other.p + p);
160 template<
class Type2>
192 return (*
this)[col][row];
198 return (*
this)[col][row];
212 return m.transformTranspose(other);
224 return m.transformTranspose(other - p);
230 return PxMat34T(m.transformTranspose(other.m.column0),
231 m.transformTranspose(other.m.column1),
232 m.transformTranspose(other.m.column2),
233 m.transformTranspose(other.p - p));
239 return PxMat34T(m.getTranspose(), m.transformTranspose(-p));
243 PX_CUDA_CALLABLE
PX_FORCE_INLINE const PxVec3T<Type>& operator[](PxU32 num)
const {
return (&m.column0)[num]; }
258typedef PxMat34T<float> PxMat34;
259typedef PxMat34T<double> PxMat34d;
3x3 matrix class
Definition PxMat33.h:91
A padded version of PxMat34, to safely load its data using SIMD.
Definition PxMat34.h:263
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T(const PxMat33T< Type > &other, const PxVec3T< Type > &t)
Construct from a 3x3 matrix and a translation vector.
Definition PxMat34.h:76
PX_CUDA_CALLABLE PX_FORCE_INLINE Type & operator()(PxU32 row, PxU32 col)
Element access, mathematical way!
Definition PxMat34.h:196
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T(const PxMat33T< Type > &other)
Construct from a 3x3 matrix.
Definition PxMat34.h:70
PX_CUDA_CALLABLE PX_FORCE_INLINE Type operator()(PxU32 row, PxU32 col) const
Element access, mathematical way!
Definition PxMat34.h:190
PX_CUDA_CALLABLE PX_FORCE_INLINE const PxMat34T & operator=(const PxMat34T &other)
Assignment operator.
Definition PxMat34.h:93
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T(const PxMat34T &other)
Copy constructor.
Definition PxMat34.h:88
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T getInverseRT() const
Invert matrix treating it as a rotation+translation matrix only.
Definition PxMat34.h:237
PX_CUDA_CALLABLE PX_FORCE_INLINE PxVec3T< Type > rotateTranspose(const PxVec3T< Type > &other) const
Transform vector by transpose of matrix, equal to v' = M^t*v.
Definition PxMat34.h:210
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T(const PxTransformT< Type > &other)
Construct from a PxTransformT<Type>
Definition PxMat34.h:82
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T(Type values[])
Construct from Type[12].
Definition PxMat34.h:64
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T & operator-=(const PxMat34T &other)
Equals-sub.
Definition PxMat34.h:174
PX_CUDA_CALLABLE PX_FORCE_INLINE PxVec3T< Type > rotate(const PxVec3T< Type > &other) const
Transform vector by matrix, equal to v' = M*v.
Definition PxMat34.h:204
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T & operator*=(Type scalar)
Equals scalar multiplication.
Definition PxMat34.h:182
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T operator*(const PxMat33T< Type > &other) const
Matrix multiplication, extend the second matrix.
Definition PxMat34.h:153
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T()
Default constructor.
Definition PxMat34.h:53
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T operator*(Type scalar) const
Scalar multiplication.
Definition PxMat34.h:139
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T & operator+=(const PxMat34T &other)
Equals-add.
Definition PxMat34.h:166
PX_CUDA_CALLABLE PX_FORCE_INLINE void setIdentity()
Set to identity matrix.
Definition PxMat34.h:101
PX_CUDA_CALLABLE PX_FORCE_INLINE bool operator!=(const PxMat34T &other) const
Inequality operator.
Definition PxMat34.h:115
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T operator*(const PxMat34T &other) const
Matrix multiplication.
Definition PxMat34.h:145
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T transformTranspose(const PxMat34T &other) const
Transform point by transposed matrix.
Definition PxMat34.h:228
PX_CUDA_CALLABLE PX_FORCE_INLINE PxVec3T< Type > transform(const PxVec3T< Type > &other) const
Transform point by matrix.
Definition PxMat34.h:216
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T operator-(const PxMat34T &other) const
Subtract.
Definition PxMat34.h:133
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T(const PxVec3T< Type > &b0, const PxVec3T< Type > &b1, const PxVec3T< Type > &b2, const PxVec3T< Type > &b3)
Construct from four base vectors.
Definition PxMat34.h:58
PX_CUDA_CALLABLE PX_FORCE_INLINE PxVec3T< Type > transformTranspose(const PxVec3T< Type > &other) const
Transform point by transposed matrix.
Definition PxMat34.h:222
PX_CUDA_CALLABLE PX_FORCE_INLINE bool operator==(const PxMat34T &other) const
Equality operator.
Definition PxMat34.h:109
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T operator-() const
Unary minus.
Definition PxMat34.h:121
PX_CUDA_CALLABLE PX_FORCE_INLINE PxMat34T operator+(const PxMat34T &other) const
Add.
Definition PxMat34.h:127
3 Element vector class.
Definition PxVec3.h:50
#define PX_FORCE_INLINE
Definition PxPreprocessor.h:335
#define PX_COMPILE_TIME_ASSERT(exp)
Definition PxPreprocessor.h:428
#define PX_INLINE
Definition PxPreprocessor.h:320
Sorts an array of objects in ascending order, assuming that the predicate implements the < operator:
Definition PxBoxController.h:39