J3D setup (#155)

* setup j3d classes

* remove asm

* fixes

* fix newDifferedDisplayList
This commit is contained in:
TakaRikka
2021-10-11 09:38:53 -07:00
committed by GitHub
parent 5084413cb7
commit a2636e84c3
134 changed files with 3399 additions and 4786 deletions
+19
View File
@@ -3,4 +3,23 @@
#include "dolphin/types.h"
struct GDLObj {
/* 0x0 */ u8* start;
/* 0x4 */ u32 length;
/* 0x8 */ u8* ptr;
/* 0xC */ u8* end;
}; // Size: 0x10
extern "C" void GDInitGDLObj(GDLObj*, u8*, u32);
extern GDLObj* __GDCurrentDL;
inline void GDSetCurrent(GDLObj* obj) {
__GDCurrentDL = obj;
}
inline u32 GDGetGDLObjOffset(GDLObj* obj) {
return (u32)(obj->ptr - obj->start);
}
#endif /* GDBASE_H */
+2 -2
View File
@@ -10,11 +10,11 @@ typedef struct _GXColor {
u8 a;
} GXColor;
struct _GXColorS10 {
typedef struct _GXColorS10 {
s16 r;
s16 g;
s16 b;
s16 a;
};
} GXColorS10;
#endif /* GXTEXTURE_H */
+3
View File
@@ -6,6 +6,9 @@
#include "dolphin/types.h"
typedef float Mtx[3][4];
typedef float Mtx33[3][3];
typedef float Mtx23[2][3];
typedef f32 (*MtxP)[4];
extern "C" {
void PSMTXIdentity(Mtx matrix);
+10
View File
@@ -23,6 +23,16 @@ struct Vec {
}
};
struct SVec {
s16 x, y, z;
void set(s16 oX, s16 oY, s16 oZ) {
x = oX;
y = oY;
z = oZ;
}
};
extern "C" {
void PSVECAdd(const Vec* src_a, const Vec* src_b, Vec* dst);
void PSVECSubtract(const Vec* a, const Vec* b, Vec* dst);