d_kankyo_wether / d_eye_hl (#178)

* d_eye_hl / d_kankyo_wether wip

* more d_kankyo_wether + format

* remove asm

* some d_kankyo wip

* fix dccs vtable

* some m_Do_graphic / d_meter2_draw work
This commit is contained in:
TakaRikka
2022-01-25 12:24:14 -08:00
committed by GitHub
parent 6f4d068f1d
commit 612f26c132
241 changed files with 3715 additions and 9755 deletions
+1
View File
@@ -103,6 +103,7 @@ public:
bool isVisible() const { return mVisible; }
void show() { mVisible = true; }
void hide() { mVisible = false; }
void initiate();
void initialize(J2DPane*, bool, u64, const JGeometry::TBox2<f32>&);
+2 -2
View File
@@ -63,8 +63,8 @@ public:
/* 80053C6C */ virtual void setBlack(JUtility::TColor);
/* 80053C44 */ virtual void setWhite(JUtility::TColor);
/* 8018BEE0 */ virtual void setBlackWhite(JUtility::TColor, JUtility::TColor);
/* 801DFA4C */ virtual void getBlack() const;
/* 801DFA40 */ virtual void getWhite() const;
/* 801DFA4C */ virtual JUtility::TColor getBlack() const;
/* 801DFA40 */ virtual JUtility::TColor getWhite() const;
/* 8025603C */ virtual bool getMaterial() const;
/* 802FDBFC */ virtual void drawFullSet(f32, f32, f32, f32, Mtx*);
/* 802FE380 */ virtual void drawTexCoord(f32, f32, f32, f32, s16, s16, s16, s16, s16, s16, s16,
+21
View File
@@ -19,6 +19,11 @@ enum J2DTextBoxHBinding {
class J2DTextBox : public J2DPane {
public:
struct TFontSize {
/* 0x0 */ f32 mSizeX;
/* 0x4 */ f32 mSizeY;
};
/* 803001E0 */ virtual ~J2DTextBox();
/* 80300C68 */ virtual s32 getTypeID() const;
/* 80300AF8 */ virtual void resize(f32, f32);
@@ -51,6 +56,22 @@ public:
/* 8030074C */ s32 setString(s16, char const*, ...);
/* 80300660 */ s32 setString(char const*, ...);
void setFontSize(f32 sizeX, f32 sizeY) {
if (sizeX > 0.0f) {
sizeX = 0.0f;
}
field_0x11c = sizeX;
if (sizeY > 0.0f) {
sizeY = 0.0f;
}
field_0x120 = sizeY;
}
void setFontSize(TFontSize size) { setFontSize(size.mSizeX, size.mSizeY); }
void setCharSpace(f32 space) { mCharSpacing = space; }
private:
/* 0x0100 */ JUTFont* mFont;
/* 0x0104 */ JUtility::TColor mCharColor;
@@ -30,6 +30,7 @@ public:
J3DMaterial* getMaterialNodePointer(u16 idx) const { return mMaterialNodePointer[idx]; }
J3DTexture* getTexture() const { return mTexture; }
JUTNameTab* getTextureName() const { return mTextureName; }
u16 getMaterialNum() const { return mMaterialNum; }
@@ -67,6 +67,7 @@ public:
J3DShapePacket* getShapePacket(u16 idx) const { return &mShapePacket[idx]; }
Mtx33* getBumpMtxPtr(int idx) const { return mMtxBuffer->getBumpMtxPtr(idx); }
Mtx33* getNrmMtxPtr() const { return mMtxBuffer->getNrmMtxPtr(); }
void setBaseScale(const Vec& scale) { mBaseScale = scale; }
// is there a better way to handle inlines with same name as non-inlines?
MtxP i_getAnmMtx(int p1) { return mMtxBuffer->getAnmMtx(p1); }
@@ -34,6 +34,7 @@ public:
J3DJoint* getJointNodePointer(u16 idx) const { return mJointTree.getJointNodePointer(idx); }
J3DJointTree& getJointTree() { return mJointTree; }
J3DTexture* getTexture() const { return mMaterialTable.getTexture(); }
JUTNameTab* getTextureName() const { return mMaterialTable.getTextureName(); }
u16 getWEvlpMtxNum() const { return mJointTree.getWEvlpMtxNum(); }
void* getVtxPosArray() const { return mVertexData.getVtxPosArray(); }
void* getVtxNrmArray() const { return mVertexData.getVtxNrmArray(); }
+1 -1
View File
@@ -66,7 +66,7 @@ public:
virtual bool entry(J3DDrawBuffer*);
virtual void draw();
virtual ~J3DPacket();
virtual ~J3DPacket() {}
public:
/* 0x04 */ J3DPacket* mpNextSibling;
+16 -1
View File
@@ -11,6 +11,11 @@ enum J3DError {
kJ3DError_Alloc = 4,
};
enum J3DSysDrawBuffer {
/* 0x0 */ OPA_BUFFER,
/* 0x1 */ XLU_BUFFER
};
class J3DMtxCalc;
class J3DModel;
class J3DMatPacket;
@@ -64,7 +69,7 @@ struct J3DSys {
/* 0x4 */ XLU,
};
Mtx* getViewMtx() { return &mViewMtx; }
MtxP getViewMtx() { return mViewMtx; }
void setDrawModeOpaTexEdge() { mDrawMode = OPA_TEX_EDGE; }
@@ -102,6 +107,16 @@ struct J3DSys {
GXSetArray(GX_NRM_MTX_ARRAY, mModelNrmMtx, sizeof(*mModelNrmMtx));
}
// Type 0: Opa Buffer
// Type 1: Xlu Buffer
void setDrawBuffer(J3DDrawBuffer* buffer, int type) { mDrawBuffer[type] = buffer; }
// Type 0: Opa Buffer
// Type 1: Xlu Buffer
J3DDrawBuffer* getDrawBuffer(int type) { return mDrawBuffer[type]; }
void setViewMtx(Mtx m) { PSMTXCopy(m, mViewMtx); }
static Mtx mCurrentMtx;
static Vec mCurrentS;
static Vec mParentS;
+4 -1
View File
@@ -9,13 +9,16 @@
class J3DTexture {
private:
/* 0x0 */ u16 mNum;
/* 0x4 */ ResTIMG** mpRes;
/* 0x4 */ ResTIMG* mpRes;
public:
/* 8031204C */ void loadGX(u16, _GXTexMapID) const;
/* 803121A4 */ void entryNum(u16);
/* 8031221C */ void addResTIMG(u16, ResTIMG const*);
/* 803366A4 */ virtual ~J3DTexture();
u16 getNum() const { return mNum; }
ResTIMG* getResTIMG(u16 entry) const { return &mpRes[entry]; }
};
struct J3DTextureSRTInfo {
+4
View File
@@ -218,4 +218,8 @@ inline JKRCompression JKRConvertAttrToCompressionType(u32 attr) {
return JKRArchive::convertAttrToCompressionType(attr);
}
inline void* JKRGetTypeResource(u32 tag, const char* name, JKRArchive* arc) {
return JKRArchive::getGlbResource(tag, name, arc);
}
#endif
+4
View File
@@ -54,4 +54,8 @@ public:
static JSUList<JKRFileLoader> sVolumeList;
};
inline void* JKRGetNameResource(const char* name, JKRFileLoader* loader) {
return JKRFileLoader::getGlbResource(name, loader);
}
#endif /* JKRFILELOADER_H */
+2 -2
View File
@@ -221,8 +221,8 @@ inline JKRHeap* JKRGetCurrentHeap() {
return JKRHeap::getCurrentHeap();
}
inline u32 JKRGetMemBlockSize(JKRHeap* heap,void* block) {
return JKRHeap::getSize(block,heap);
inline u32 JKRGetMemBlockSize(JKRHeap* heap, void* block) {
return JKRHeap::getSize(block, heap);
}
#endif /* JKRHEAP_H */
+2
View File
@@ -124,6 +124,8 @@ public:
return isPushingReset;
}
static s8 getPortStatus(u32 port) { return mPadStatus[port].error; }
struct CButton {
CButton(); // inline
void clear();
+2
View File
@@ -66,6 +66,8 @@ public:
void idleStart() { mIdle.start(255, 129, 30); }
void idleEnd() { mIdle.end(); }
void setCostFrame(int frame) { mCostFrame = frame; }
void setVisible(bool visible) { mVisible = visible; }
void setVisibleHeapBar(bool visible) { mHeapBarVisible = visible; }
static JUTProcBar* getManager() { return sManager; }