mirror of
https://github.com/zeldaret/tp
synced 2026-06-14 14:28:14 -04:00
@@ -24,8 +24,7 @@ public:
|
||||
|
||||
const JGeometry::TBox2<f32>* getOrtho() const { return &mOrtho; }
|
||||
void setOrtho(f32 x, f32 y, f32 width, f32 height, f32 far, f32 near) {
|
||||
JGeometry::TBox2<f32> ortho(x, y, x + width, y + height);
|
||||
setOrtho(ortho, far, near);
|
||||
setOrtho(JGeometry::TBox2<f32>(x, y, x + width, y + height), far, near);
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
@@ -1,7 +1,6 @@
|
||||
#ifndef J3DANIMATION_H
|
||||
#define J3DANIMATION_H
|
||||
|
||||
#include "JSystem/J3DGraphAnimator/J3DJoint.h"
|
||||
#include "JSystem/J3DGraphAnimator/J3DModelData.h"
|
||||
#include "JSystem/JUtility/JUTAssert.h"
|
||||
#include "JSystem/JUtility/JUTNameTab.h"
|
||||
@@ -978,52 +977,4 @@ public:
|
||||
/* 0x10 */ f32 mFrame;
|
||||
}; // Size: 0x14
|
||||
|
||||
struct J3DMtxCalcAnmBase: public J3DMtxCalc {
|
||||
J3DMtxCalcAnmBase(J3DAnmTransform* pAnmTransform) { mAnmTransform = pAnmTransform; }
|
||||
~J3DMtxCalcAnmBase() {}
|
||||
J3DAnmTransform* getAnmTransform() { return mAnmTransform; }
|
||||
void setAnmTransform(J3DAnmTransform* pAnmTransform) { mAnmTransform = pAnmTransform; }
|
||||
|
||||
J3DAnmTransform* mAnmTransform;
|
||||
};
|
||||
|
||||
struct J3DMtxCalcAnimationAdaptorBase {
|
||||
J3DMtxCalcAnimationAdaptorBase() {}
|
||||
void change(J3DAnmTransform*) {}
|
||||
};
|
||||
|
||||
template <typename A0>
|
||||
struct J3DMtxCalcAnimationAdaptorDefault : public J3DMtxCalcAnimationAdaptorBase {
|
||||
J3DMtxCalcAnimationAdaptorDefault(J3DAnmTransform* pAnmTransform) {}
|
||||
|
||||
void calc(J3DMtxCalcAnmBase* pMtxCalc) {
|
||||
J3DTransformInfo transform;
|
||||
J3DTransformInfo* transform_p;
|
||||
if (pMtxCalc->getAnmTransform() != NULL) {
|
||||
pMtxCalc->getAnmTransform()->getTransform(J3DMtxCalc::getJoint()->getJntNo(), &transform);
|
||||
transform_p = &transform;
|
||||
} else {
|
||||
transform_p = &J3DMtxCalc::getJoint()->getTransformInfo();
|
||||
}
|
||||
|
||||
A0::calcTransform(*transform_p);
|
||||
}
|
||||
};
|
||||
|
||||
template <typename A0, typename B0>
|
||||
struct J3DMtxCalcAnimation : public J3DMtxCalcAnmBase {
|
||||
J3DMtxCalcAnimation(J3DAnmTransform* pAnmTransform) : J3DMtxCalcAnmBase(pAnmTransform), field_0x8(pAnmTransform) {}
|
||||
~J3DMtxCalcAnimation() {}
|
||||
|
||||
void setAnmTransform(J3DAnmTransform* pAnmTransform) {
|
||||
mAnmTransform = pAnmTransform;
|
||||
field_0x8.change(pAnmTransform);
|
||||
}
|
||||
|
||||
void init(const Vec& param_0, const Mtx& param_1) { B0::init(param_0, param_1); }
|
||||
void calc() { field_0x8.calc(this); }
|
||||
|
||||
A0 field_0x8;
|
||||
};
|
||||
|
||||
#endif /* J3DANIMATION_H */
|
||||
|
||||
@@ -145,6 +145,54 @@ public:
|
||||
}
|
||||
};
|
||||
|
||||
struct J3DMtxCalcAnmBase: public J3DMtxCalc {
|
||||
J3DMtxCalcAnmBase(J3DAnmTransform* pAnmTransform) { mAnmTransform = pAnmTransform; }
|
||||
~J3DMtxCalcAnmBase() {}
|
||||
J3DAnmTransform* getAnmTransform() { return mAnmTransform; }
|
||||
void setAnmTransform(J3DAnmTransform* pAnmTransform) { mAnmTransform = pAnmTransform; }
|
||||
|
||||
J3DAnmTransform* mAnmTransform;
|
||||
};
|
||||
|
||||
struct J3DMtxCalcAnimationAdaptorBase {
|
||||
J3DMtxCalcAnimationAdaptorBase() {}
|
||||
void change(J3DAnmTransform*) {}
|
||||
};
|
||||
|
||||
template <typename A0>
|
||||
struct J3DMtxCalcAnimationAdaptorDefault : public J3DMtxCalcAnimationAdaptorBase {
|
||||
J3DMtxCalcAnimationAdaptorDefault(J3DAnmTransform* pAnmTransform) {}
|
||||
|
||||
void calc(J3DMtxCalcAnmBase* pMtxCalc) {
|
||||
J3DTransformInfo transform;
|
||||
J3DTransformInfo* transform_p;
|
||||
if (pMtxCalc->getAnmTransform() != NULL) {
|
||||
pMtxCalc->getAnmTransform()->getTransform(J3DMtxCalc::getJoint()->getJntNo(), &transform);
|
||||
transform_p = &transform;
|
||||
} else {
|
||||
transform_p = &J3DMtxCalc::getJoint()->getTransformInfo();
|
||||
}
|
||||
|
||||
A0::calcTransform(*transform_p);
|
||||
}
|
||||
};
|
||||
|
||||
template <typename A0, typename B0>
|
||||
struct J3DMtxCalcAnimation : public J3DMtxCalcAnmBase {
|
||||
J3DMtxCalcAnimation(J3DAnmTransform* pAnmTransform) : J3DMtxCalcAnmBase(pAnmTransform), field_0x8(pAnmTransform) {}
|
||||
~J3DMtxCalcAnimation() {}
|
||||
|
||||
void setAnmTransform(J3DAnmTransform* pAnmTransform) {
|
||||
mAnmTransform = pAnmTransform;
|
||||
field_0x8.change(pAnmTransform);
|
||||
}
|
||||
|
||||
void init(const Vec& param_0, const Mtx& param_1) { B0::init(param_0, param_1); }
|
||||
void calc() { field_0x8.calc(this); }
|
||||
|
||||
A0 field_0x8;
|
||||
};
|
||||
|
||||
/**
|
||||
* @ingroup jsystem-j3d
|
||||
*
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
#ifndef J3DJOINTTREE_H
|
||||
#define J3DJOINTTREE_H
|
||||
|
||||
#include "JSystem/J3DAssert.h"
|
||||
#include "JSystem/J3DGraphBase/J3DTransform.h"
|
||||
|
||||
class J3DJoint;
|
||||
|
||||
@@ -32,7 +32,7 @@ public:
|
||||
static u32 fetchResource_subroutine(u8*, u32, u8*, u32, JKRCompression);
|
||||
SArcHeader* getArcHeader() { return mArcHeader; }
|
||||
|
||||
private:
|
||||
public:
|
||||
/* 0x00 */ // vtable
|
||||
/* 0x04 */ // JKRArchive
|
||||
/* 0x64 */ SArcHeader* mArcHeader;
|
||||
|
||||
@@ -6,6 +6,20 @@
|
||||
#include "JSystem/JUtility/JUTFont.h"
|
||||
#include <cstdarg>
|
||||
|
||||
class JUTConsole;
|
||||
|
||||
extern "C" void JUTConsole_print_f_va_(JUTConsole*, const char*, va_list);
|
||||
extern "C" void JUTSetReportConsole(JUTConsole*);
|
||||
extern "C" JUTConsole* JUTGetReportConsole();
|
||||
extern "C" void JUTSetWarningConsole(JUTConsole*);
|
||||
extern "C" JUTConsole* JUTGetWarningConsole();
|
||||
extern "C" void JUTWarningConsole_f_va(const char*, va_list);
|
||||
extern "C" void JUTReportConsole_f_va(const char*, va_list);
|
||||
extern "C" void JUTReportConsole_f(const char*, ...);
|
||||
extern "C" void JUTWarningConsole(const char* message);
|
||||
extern "C" void JUTWarningConsole_f(const char* message, ...);
|
||||
extern "C" void JUTReportConsole(const char* message);
|
||||
|
||||
/**
|
||||
* @ingroup jsystem-jutility
|
||||
*
|
||||
@@ -95,6 +109,7 @@ public:
|
||||
|
||||
void scrollToLastLine() { scroll(mMaxLines); }
|
||||
void scrollToFirstLine() { scroll(-mMaxLines); }
|
||||
void print_f_va(const char* fmt, va_list args) { JUTConsole_print_f_va_(this, fmt, args); }
|
||||
|
||||
/* 0x18 */ JGadget::TLinkListNode mListNode;
|
||||
/* 0x20 */ unsigned int field_0x20;
|
||||
@@ -154,16 +169,4 @@ private:
|
||||
/* 0x10 */ JUTConsole* mDirectConsole;
|
||||
}; // Size: 0x14
|
||||
|
||||
extern "C" void JUTConsole_print_f_va_(JUTConsole*, const char*, va_list);
|
||||
extern "C" void JUTSetReportConsole(JUTConsole*);
|
||||
extern "C" JUTConsole* JUTGetReportConsole();
|
||||
extern "C" void JUTSetWarningConsole(JUTConsole*);
|
||||
extern "C" JUTConsole* JUTGetWarningConsole();
|
||||
extern "C" void JUTWarningConsole_f_va(const char*, va_list);
|
||||
extern "C" void JUTReportConsole_f_va(const char*, va_list);
|
||||
extern "C" void JUTReportConsole_f(const char*, ...);
|
||||
extern "C" void JUTWarningConsole(const char* message);
|
||||
extern "C" void JUTWarningConsole_f(const char* message, ...);
|
||||
extern "C" void JUTReportConsole(const char* message);
|
||||
|
||||
#endif /* JUTCONSOLE_H */
|
||||
|
||||
Reference in New Issue
Block a user