From b428f8884093d919777695d66e054b21bd7a64ea Mon Sep 17 00:00:00 2001 From: Lord-Giganticus <70081529+Lord-Giganticus@users.noreply.github.com> Date: Wed, 18 Sep 2024 12:10:01 -0500 Subject: [PATCH] JGeometry Matrix identity --- csv/Animation.csv | 2 +- data/Game.json | 2 +- data/json/Animation.json | 2 +- docs/PROGRESS.md | 2 +- docs/lib/Game/Animation.md | 2 +- docs/lib/Game/Animation/AnmPlayer.md | 4 ++-- .../include/JSystem/JGeometry/TMatrix.hpp | 18 ++++++++++++++++++ 7 files changed, 25 insertions(+), 7 deletions(-) diff --git a/csv/Animation.csv b/csv/Animation.csv index dfcfe9237..1d7344385 100644 --- a/csv/Animation.csv +++ b/csv/Animation.csv @@ -5,7 +5,7 @@ slerp__Q29JGeometry9TQuat4FRCQ29JGeometry9TQuat4f,AnmPlayer.o,Animation.a, normalize__Q29JGeometry9TQuat4FRCQ29JGeometry9TQuat4,AnmPlayer.o,Animation.a,false getEuler__Q29JGeometry9TQuat4CFRQ29JGeometry8TVec3,AnmPlayer.o,Animation.a,false __ct__Q29JGeometry64TPosition3>>Fv,AnmPlayer.o,Animation.a,false -identity__Q29JGeometry38TMatrix34>Fv,AnmPlayer.o,Animation.a,false +identity__Q29JGeometry38TMatrix34>Fv,AnmPlayer.o,Animation.a,true mult__Q29JGeometry38TMatrix34>CFRCQ29JGeometry8TVec3RQ29JGeometry8TVec3,AnmPlayer.o,Animation.a,false multTranspose__Q29JGeometry38TMatrix34>CFRCQ29JGeometry8TVec3RQ29JGeometry8TVec3,AnmPlayer.o,Animation.a,false invert__Q29JGeometry38TMatrix34>FRCQ29JGeometry38TMatrix34>,AnmPlayer.o,Animation.a,false diff --git a/data/Game.json b/data/Game.json index 4cd41cdfd..4b8dcfacd 100644 --- a/data/Game.json +++ b/data/Game.json @@ -1,6 +1,6 @@ { "schemaVersion": 1, "label": "Game", - "message": "16.255%", + "message": "16.257%", "color": "blue" } \ No newline at end of file diff --git a/data/json/Animation.json b/data/json/Animation.json index 595a53610..a2b2d81ab 100644 --- a/data/json/Animation.json +++ b/data/json/Animation.json @@ -1,6 +1,6 @@ { "schemaVersion": 1, "label": "Animation", - "message": "5.303%", + "message": "5.51%", "color": "yellow" } \ No newline at end of file diff --git a/docs/PROGRESS.md b/docs/PROGRESS.md index 69c30570c..63b68788e 100644 --- a/docs/PROGRESS.md +++ b/docs/PROGRESS.md @@ -1,7 +1,7 @@ # Game | Library | Percentage | | ------------- | ------------- | -| [Animation](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/Animation.md) | 5.303240099695375% | +| [Animation](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/Animation.md) | 5.5109387981168645% | | [AreaObj](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/AreaObj.md) | 58.466557911908644% | | [AudioLib](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/AudioLib.md) | 0.0% | | [Boss](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/Boss.md) | 13.879584746291634% | diff --git a/docs/lib/Game/Animation.md b/docs/lib/Game/Animation.md index 35bdc108d..c073f05a2 100644 --- a/docs/lib/Game/Animation.md +++ b/docs/lib/Game/Animation.md @@ -8,7 +8,7 @@ | Object | Percentage (of Bytes) | Functions Done / Total Functions | Percentage (Functions) | Status | ------------- | ------------- | ------------- | ------------- | ------------- -| [AnmPlayer.o](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/Animation/AnmPlayer.md) | 8.843537414965986% | 10 / 32 | 31.25% | :eight_pointed_black_star: +| [AnmPlayer.o](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/Animation/AnmPlayer.md) | 9.863945578231291% | 11 / 32 | 34.375% | :eight_pointed_black_star: | [BckCtrl.o](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/Animation/BckCtrl.md) | 18.295218295218298% | 3 / 9 | 33.33333333333333% | :eight_pointed_black_star: | [BpkPlayer.o](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/Animation/BpkPlayer.md) | 0.0% | 0 / 3 | 0.0% | :x: | [BrkPlayer.o](https://github.com/shibbo/Petari/blob/master/docs/lib/Game/Animation/BrkPlayer.md) | 0.0% | 0 / 3 | 0.0% | :x: diff --git a/docs/lib/Game/Animation/AnmPlayer.md b/docs/lib/Game/Animation/AnmPlayer.md index b8507accc..51ca25f9e 100644 --- a/docs/lib/Game/Animation/AnmPlayer.md +++ b/docs/lib/Game/Animation/AnmPlayer.md @@ -5,7 +5,7 @@ | :white_check_mark: | Function is completed. -# 10 / 32 Completed -- (31.25%) +# 11 / 32 Completed -- (34.375%) # AnmPlayer.o | Symbol | Decompiled? | | ------------- | ------------- | @@ -15,7 +15,7 @@ | `normalize__Q29JGeometry9TQuat4FRCQ29JGeometry9TQuat4` | :x: | | `getEuler__Q29JGeometry9TQuat4CFRQ29JGeometry8TVec3` | :x: | | `__ct__Q29JGeometry64TPosition3>>Fv` | :x: | -| `identity__Q29JGeometry38TMatrix34>Fv` | :x: | +| `identity__Q29JGeometry38TMatrix34>Fv` | :white_check_mark: | | `mult__Q29JGeometry38TMatrix34>CFRCQ29JGeometry8TVec3RQ29JGeometry8TVec3` | :x: | | `multTranspose__Q29JGeometry38TMatrix34>CFRCQ29JGeometry8TVec3RQ29JGeometry8TVec3` | :x: | | `invert__Q29JGeometry38TMatrix34>FRCQ29JGeometry38TMatrix34>` | :x: | diff --git a/libs/JSystem/include/JSystem/JGeometry/TMatrix.hpp b/libs/JSystem/include/JSystem/JGeometry/TMatrix.hpp index 4960524c9..1fc415821 100644 --- a/libs/JSystem/include/JSystem/JGeometry/TMatrix.hpp +++ b/libs/JSystem/include/JSystem/JGeometry/TMatrix.hpp @@ -268,3 +268,21 @@ typedef JGeometry::SMatrix34C TSMtxf; typedef JGeometry::TMatrix34 TMtx34f; typedef JGeometry::TRotation3 TRot3f; typedef JGeometry::TPosition3 TPos3f; + + +template <> +void JGeometry::TMatrix34::identity() { + float v0 = 1.0, v1 = 0.0; + mMtx[2][3] = v1; + mMtx[1][3] = v1; + mMtx[0][3] = v1; + mMtx[1][2] = v1; + mMtx[0][2] = v1; + mMtx[2][1] = v1; + mMtx[0][1] = v1; + mMtx[2][0] = v1; + mMtx[1][0] = v1; + mMtx[2][2] = v0; + mMtx[1][1] = v0; + mMtx[0][0] = v0; +} \ No newline at end of file