diff options
author | Toni Uhlig <matzeton@googlemail.com> | 2019-10-05 19:00:09 +0200 |
---|---|---|
committer | Toni Uhlig <matzeton@googlemail.com> | 2019-10-05 19:00:09 +0200 |
commit | 480a5ce0ee31646c8f696d3f0572d0e3453c3d36 (patch) | |
tree | 0aa123adb4523ca981aef88b958b9d418e5dc742 /TestDLL | |
parent | c2f81cc2ecf1d793f4e3648fac05c7ac444570b4 (diff) |
moved Matrix34 below Vec3 and inlined Transform routine to Matrix34
Diffstat (limited to 'TestDLL')
-rw-r--r-- | TestDLL/HuntClasses.h | 36 |
1 files changed, 16 insertions, 20 deletions
diff --git a/TestDLL/HuntClasses.h b/TestDLL/HuntClasses.h index b3796b6..f7807e5 100644 --- a/TestDLL/HuntClasses.h +++ b/TestDLL/HuntClasses.h @@ -13,22 +13,6 @@ struct ISystem; #define ENTITY_FLAG_SEND_RENDER_EVENT 0x20000 #define ENTITY_FLAG_CASTSHADOW 0x1 -class Matrix34 { -public: - float m00; - float m01; - float m02; - float m03; - float m10; - float m11; - float m12; - float m13; - float m20; - float m21; - float m22; - float m23; -}; - template<class _I> class _smart_ptr { private: @@ -157,7 +141,6 @@ struct INumberVector : INumberArray<T, N> { }; -template<typename F> struct Vec3_tpl; template<typename F> struct Vec3_tpl : INumberVector<F, 3, Vec3_tpl<F>> { @@ -167,9 +150,22 @@ public: }; typedef Vec3_tpl<float> Vec3; -static inline Vec3_tpl<float> TranslateMat34ToVec3(const Matrix34 &mat34) { - return Vec3_tpl<float>(mat34.m03, mat34.m13, mat34.m23); -} +class Matrix34 { +public: + float m00; + float m01; + float m02; + float m03; + float m10; + float m11; + float m12; + float m13; + float m20; + float m21; + float m22; + float m23; + Vec3 GetTranslation() const { return Vec3(m03, m13, m23); } +}; enum EDrawTextFlags : UINT32 { |