move jasper's jsystem work over

This commit is contained in:
TakaRikka
2022-10-04 21:17:53 -07:00
parent a3578d0c7c
commit 74c248990c
37 changed files with 153 additions and 1292 deletions
+10 -8
View File
@@ -51,29 +51,29 @@ public:
class J3DPacket {
public:
J3DPacket() {
mpNextSibling = NULL;
mpNextPacket = NULL;
mpFirstChild = NULL;
mpUserData = NULL;
}
void addChildPacket(J3DPacket*);
J3DPacket* getNextPacket() const { return mpNextSibling; }
void setNextPacket(J3DPacket* i_packet) { mpNextSibling = i_packet; }
J3DPacket* getNextPacket() const { return mpNextPacket; }
void setNextPacket(J3DPacket* i_packet) { mpNextPacket = i_packet; }
void drawClear() {
mpNextSibling = NULL;
mpNextPacket = NULL;
mpFirstChild = NULL;
}
void setUserArea(u32 area) { mpUserData = (void*)area; }
virtual bool entry(J3DDrawBuffer*);
virtual int entry(J3DDrawBuffer*);
virtual void draw();
virtual ~J3DPacket() {}
public:
/* 0x04 */ J3DPacket* mpNextSibling;
/* 0x04 */ J3DPacket* mpNextPacket;
/* 0x08 */ J3DPacket* mpFirstChild;
/* 0x0C */ void* mpUserData;
}; // Size: 0x10
@@ -145,19 +145,21 @@ public:
void endDiff();
bool isSame(J3DMatPacket*) const;
J3DMaterial* getMaterial() const { return mpMaterial; }
J3DShapePacket* getShapePacket() const { return mpShapePacket; }
void setShapePacket(J3DShapePacket* packet) { mpShapePacket = packet; }
void setInitShapePacket(J3DShapePacket* packet) { mpInitShapePacket = packet; }
bool isChanged() const { return mDiffFlag < 0; }
virtual ~J3DMatPacket();
virtual bool entry(J3DDrawBuffer*);
virtual int entry(J3DDrawBuffer*);
virtual void draw();
public:
/* 0x28 */ J3DShapePacket* mpInitShapePacket;
/* 0x2C */ J3DShapePacket* mpShapePacket;
/* 0x30 */ J3DMaterial* mpMaterial;
/* 0x34 */ u32 mSortFlags;
/* 0x34 */ u32 mDiffFlag;
/* 0x38 */ J3DTexture* mpTexture;
/* 0x3C */ J3DMaterialAnm* mpMaterialAnm;
}; // Size: 0x40
+3
View File
@@ -93,6 +93,9 @@ struct J3DSys {
void setMaterialMode(u32 mode) { mMaterialMode = mode; }
void setTexture(J3DTexture* pTex) { mTexture = pTex; }
J3DTexture* getTexture() { return mTexture; }
void setNBTScale(Vec* scale) { mNBTScale = scale; }
void onFlag(u32 flag) { mFlags |= flag; }
+4 -3
View File
@@ -1,13 +1,14 @@
#ifndef J3DTRANSFORM_H
#define J3DTRANSFORM_H
#include "JSystem/JGeometry.h"
#include "dolphin/mtx/mtxvec.h"
#include "dolphin/types.h"
struct J3DTransformInfo {
/* 0x00 */ Vec mScale;
/* 0x0C */ SVec mRotation;
/* 0x14 */ Vec mTranslate;
/* 0x00 */ JGeometry::TVec3<f32> mScale;
/* 0x0C */ JGeometry::TVec3<s16> mRotation;
/* 0x14 */ JGeometry::TVec3<f32> mTranslate;
}; // Size: 0x20
extern J3DTransformInfo const j3dDefaultTransformInfo;