67 lines
2.1 KiB
Plaintext
67 lines
2.1 KiB
Plaintext
// Filename: lmat_ops.I
|
|
// Created by: drose (08Mar00)
|
|
//
|
|
////////////////////////////////////////////////////////////////////
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: LVecBase3 times LMatrix3
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
template<class NumType>
|
|
INLINE LVecBase3<NumType>
|
|
operator * (const LVecBase3<NumType> &v, const LMatrix3<NumType> &m) {
|
|
return m.xform(v);
|
|
}
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: LVector2 times LMatrix3
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
template<class NumType>
|
|
INLINE LVector2<NumType>
|
|
operator * (const LVector2<NumType> &v, const LMatrix3<NumType> &m) {
|
|
return m.xform_vec(v);
|
|
}
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: LPoint2 times LMatrix3
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
template<class NumType>
|
|
INLINE LPoint2<NumType>
|
|
operator * (const LPoint2<NumType> &v, const LMatrix3<NumType> &m) {
|
|
return m.xform_point(v);
|
|
}
|
|
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: LVecBase4 times LMatrix4
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
template<class NumType>
|
|
INLINE LVecBase4<NumType>
|
|
operator * (const LVecBase4<NumType> &v, const LMatrix4<NumType> &m) {
|
|
return m.xform(v);
|
|
}
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: LVector3 times LMatrix4
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
template<class NumType>
|
|
INLINE LVector3<NumType>
|
|
operator * (const LVector3<NumType> &v, const LMatrix4<NumType> &m) {
|
|
return m.xform_vec(v);
|
|
}
|
|
|
|
////////////////////////////////////////////////////////////////////
|
|
// Function: LPoint3 times LMatrix4
|
|
// Description:
|
|
////////////////////////////////////////////////////////////////////
|
|
template<class NumType>
|
|
INLINE LPoint3<NumType>
|
|
operator * (const LPoint3<NumType> &v, const LMatrix4<NumType> &m) {
|
|
return m.xform_point(v);
|
|
}
|
|
|