Matrix/vector refactor (#426)

This commit is contained in:
Christian Semmler
2024-01-12 19:34:38 -05:00
committed by GitHub
parent eac096036a
commit d24f5db42f
41 changed files with 865 additions and 1365 deletions

View File

@@ -209,7 +209,7 @@ public:
virtual void* ImplementationDataPtr();
// vtable+0x08
virtual Result SetTransformation(const FloatMatrix4&);
virtual Result SetTransformation(FloatMatrix4&);
inline IDirect3DRMFrame2* ImplementationData() const { return m_data; }
@@ -234,7 +234,7 @@ public:
virtual void* ImplementationDataPtr();
// vtable+0x08
virtual Result SetTransformation(const FloatMatrix4&);
virtual Result SetTransformation(FloatMatrix4&);
virtual Result SetColor(float r, float g, float b);
inline IDirect3DRMFrame2* ImplementationData() const { return m_data; }
@@ -300,7 +300,7 @@ public:
virtual void* ImplementationDataPtr();
// vtable+0x08
virtual Result SetTransformation(const FloatMatrix4&);
virtual Result SetTransformation(FloatMatrix4&);
virtual Result SetColor(float r, float g, float b, float a);
// vtable+0x10
@@ -474,7 +474,7 @@ inline D3DRMPROJECTIONTYPE Translate(ProjectionType tglProjectionType)
// Yes this function serves no purpose, originally they intended it to
// convert from doubles to floats but ended up using floats throughout
// the software stack.
inline D3DRMMATRIX4D* Translate(const FloatMatrix4& tglMatrix4x4, D3DRMMATRIX4D& rD3DRMMatrix4x4)
inline D3DRMMATRIX4D* Translate(FloatMatrix4& tglMatrix4x4, D3DRMMATRIX4D& rD3DRMMatrix4x4)
{
for (int i = 0; i < (sizeof(rD3DRMMatrix4x4) / sizeof(rD3DRMMatrix4x4[0])); i++) {
for (int j = 0; j < (sizeof(rD3DRMMatrix4x4[0]) / sizeof(rD3DRMMatrix4x4[0][0])); j++) {