diff options
| author | LagoLunatic <LagoLunatic@users.noreply.github.com> | 2025-06-19 19:05:10 -0400 |
|---|---|---|
| committer | LagoLunatic <LagoLunatic@users.noreply.github.com> | 2025-06-19 19:05:10 -0400 |
| commit | 705f55693c7dce1bdcdea63c7333fcf2bcf047ee (patch) | |
| tree | 1c23bd15f5cff11e467a617eecae29d08708ee26 /include/JSystem/J3DGraphBase | |
| parent | efc33c5fc400aad29d8483411804ca8a3588997d (diff) | |
Move J3DShapeMtx to correct header for assert
Diffstat (limited to 'include/JSystem/J3DGraphBase')
| -rw-r--r-- | include/JSystem/J3DGraphBase/J3DShape.h | 36 | ||||
| -rw-r--r-- | include/JSystem/J3DGraphBase/J3DShapeMtx.h | 35 |
2 files changed, 36 insertions, 35 deletions
diff --git a/include/JSystem/J3DGraphBase/J3DShape.h b/include/JSystem/J3DGraphBase/J3DShape.h index 266636a8..791d93bc 100644 --- a/include/JSystem/J3DGraphBase/J3DShape.h +++ b/include/JSystem/J3DGraphBase/J3DShape.h @@ -2,10 +2,12 @@ #define J3DSHAPE_H #include "JSystem/J3DGraphBase/J3DShapeDraw.h" -#include "JSystem/J3DGraphBase/J3DShapeMtx.h" +#include "JSystem/JUtility/JUTAssert.h" #include "dolphin/gx/GX.h" #include "dolphin/types.h" +class J3DShapeMtx; + class J3DCurrentMtxInfo { public: /* 0x00 */ u32 mMtxIdxRegA; @@ -155,4 +157,36 @@ private: /* 0x64 */ u32 mBumpMtxOffset; }; +class J3DShapeMtx { +public: + typedef void (J3DShapeMtx::*MtxLoadIndx)(int mtxNo, u16 index) const; + + J3DShapeMtx(u16 useMtxIndex) : mUseMtxIndex(useMtxIndex) {} + + void loadMtxIndx_PNGP(int, u16) const; + void loadMtxIndx_PCPU(int, u16) const; + void loadMtxIndx_NCPU(int, u16) const; + void loadMtxIndx_PNCPU(int, u16) const; + + virtual ~J3DShapeMtx() {} + virtual u32 getType() const { return 'SMTX'; } + virtual u32 getUseMtxNum() const { return 1; } + virtual u16 getUseMtxIndex(u16) const { return mUseMtxIndex; } + virtual void load() const; + virtual void calcNBTScale(Vec const&, Mtx33*, Mtx33*); + + static MtxLoadIndx sMtxLoadPipeline[4]; + static u32 sCurrentPipeline; + static u8* sCurrentScaleFlag; + static u8 sNBTFlag; + + static void setCurrentPipeline(u32 pipeline) { + J3D_ASSERT(91, pipeline < 4, "Error : range over."); + sCurrentPipeline = pipeline; + } + +protected: + /* 0x04 */ u16 mUseMtxIndex; +}; + #endif /* J3DSHAPE_H */ diff --git a/include/JSystem/J3DGraphBase/J3DShapeMtx.h b/include/JSystem/J3DGraphBase/J3DShapeMtx.h index b379fd71..482c1588 100644 --- a/include/JSystem/J3DGraphBase/J3DShapeMtx.h +++ b/include/JSystem/J3DGraphBase/J3DShapeMtx.h @@ -1,42 +1,9 @@ #ifndef J3DSHAPEMTX_H #define J3DSHAPEMTX_H -#include "JSystem/JUtility/JUTAssert.h" +#include "JSystem/J3DGraphBase/J3DShape.h" #include "dolphin/mtx/mtx.h" -class J3DShapeMtx { -public: - typedef void (J3DShapeMtx::*MtxLoadIndx)(int mtxNo, u16 index) const; - - J3DShapeMtx(u16 useMtxIndex) : mUseMtxIndex(useMtxIndex) {} - - void loadMtxIndx_PNGP(int, u16) const; - void loadMtxIndx_PCPU(int, u16) const; - void loadMtxIndx_NCPU(int, u16) const; - void loadMtxIndx_PNCPU(int, u16) const; - - virtual ~J3DShapeMtx() {} - virtual u32 getType() const { return 'SMTX'; } - virtual u32 getUseMtxNum() const { return 1; } - virtual u16 getUseMtxIndex(u16) const { return mUseMtxIndex; } - virtual void load() const; - virtual void calcNBTScale(Vec const&, Mtx33*, Mtx33*); - - static MtxLoadIndx sMtxLoadPipeline[4]; - static u32 sCurrentPipeline; - static u8* sCurrentScaleFlag; - static u8 sNBTFlag; - - static void setCurrentPipeline(u32 pipeline) { - // TODO: needs to go in J3DShape.h for assert - J3D_ASSERT(91, pipeline < 4, "Error : range over."); - sCurrentPipeline = pipeline; - } - -protected: - /* 0x04 */ u16 mUseMtxIndex; -}; - class J3DShapeMtxImm : public J3DShapeMtx { public: typedef void (J3DShapeMtxImm::*MtxLoadImm)(int mtxNo, u16 index) const; |
