mirror of
https://github.com/zeldaret/tww.git
synced 2026-08-05 17:43:23 -04:00
c_phase match, thanks to Cuyler
also some JPA work
This commit is contained in:
@@ -222,23 +222,10 @@ struct TVec3<f32> {
|
||||
};
|
||||
}
|
||||
|
||||
void negateInternal(TVec3<f32>* dst) {
|
||||
register f32* rdst = &dst->x;
|
||||
const register f32* src = &x;
|
||||
register f32 x_y;
|
||||
register f32 z;
|
||||
asm {
|
||||
psq_l x_y, 0(src), 0, 0
|
||||
ps_neg x_y, x_y
|
||||
psq_st x_y, 0(rdst), 0, 0
|
||||
lfs z, 8(src)
|
||||
fneg z, z
|
||||
stfs z, 8(rdst)
|
||||
};
|
||||
}
|
||||
|
||||
void negate() {
|
||||
negateInternal(this);
|
||||
x = -x;
|
||||
y = -y;
|
||||
z = -z;
|
||||
}
|
||||
|
||||
void sub(const TVec3<f32>& b) {
|
||||
|
||||
@@ -70,7 +70,7 @@ public:
|
||||
virtual GXColor getPrmColor(s16) = 0;
|
||||
virtual GXColor getEnvColor(s16) = 0;
|
||||
virtual u8 getColorRegAnmType() = 0;
|
||||
virtual u32 getColorRegAnmMaxFrm() = 0;
|
||||
virtual s32 getColorRegAnmMaxFrm() = 0;
|
||||
virtual u32 isEnableTexScrollAnm() = 0;
|
||||
virtual f32 getTilingX() = 0;
|
||||
virtual f32 getTilingY() = 0;
|
||||
@@ -178,7 +178,7 @@ public:
|
||||
virtual GXColor getPrmColor(s16 idx) { return mpPrmColorArr[idx]; }
|
||||
virtual GXColor getEnvColor(s16 idx) { return mpEnvColorArr[idx]; }
|
||||
virtual u8 getColorRegAnmType() { return (pBsd->mColorFlags >> 4) & 0x07; }
|
||||
virtual u32 getColorRegAnmMaxFrm() { return pBsd->mColorRegAnmMaxFrm; }
|
||||
virtual s32 getColorRegAnmMaxFrm() { return pBsd->mColorRegAnmMaxFrm; }
|
||||
virtual u32 isEnableTexScrollAnm() { return pBsd->mFlags & 0x1000000; }
|
||||
virtual f32 getTilingX() { return pBsd->mTilingX; }
|
||||
virtual f32 getTilingY() { return pBsd->mTilingY; }
|
||||
|
||||
@@ -32,7 +32,9 @@ public:
|
||||
/* 0xA0 */ DirTypeFunc mDirTypeFunc;
|
||||
/* 0xA4 */ RotTypeFunc mRotTypeFunc;
|
||||
/* 0xA8 */ BasePlaneTypeFunc mBasePlaneTypeFunc;
|
||||
/* 0xAC */ u8 field_0xa4[0xb4 - 0xac];
|
||||
/* 0xAC */ u32 field_0xa4;
|
||||
/* 0xB0 */ s16 mColorAnmFrame;
|
||||
/* 0xB2 */ s16 field_0xb2;
|
||||
};
|
||||
|
||||
class JPADraw {
|
||||
@@ -89,7 +91,7 @@ public:
|
||||
/* 0xB4 */ f32 mScaleOut;
|
||||
/* 0xB8 */ GXColor mPrmColor;
|
||||
/* 0xBC */ GXColor mEnvColor;
|
||||
/* 0xC0 */ s16 mTexIdx;
|
||||
/* 0xC0 */ u16 mTexIdx;
|
||||
/* 0xC2 */ u8 field_0xc2;
|
||||
/* 0xC3 */ u8 field_0xc3;
|
||||
};
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
#define JPADRAWVISITOR_H
|
||||
|
||||
#include "JSystem/JSupport/JSUList.h"
|
||||
#include "JSystem/JGeometry.h"
|
||||
#include "dolphin/mtx/mtx.h"
|
||||
#include "dolphin/types.h"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user