copy dolsdk2004 to tp / b_bh + e_mb done (#2299)

* move dolsdk2004 over

* cleanup some temp work

* finish and cleanup gf

* b_bh done

* d_a_e_mb done
This commit is contained in:
TakaRikka
2025-02-10 11:20:42 -08:00
committed by GitHub
parent a38e2bfeee
commit eda175afc8
540 changed files with 68042 additions and 22075 deletions
+2 -1
View File
@@ -1,6 +1,7 @@
#ifndef J3DGD_H
#define J3DGD_H
#include <dolphin/gx.h>
#include "dolphin/gd/GDBase.h"
inline void J3DGDWrite_u8(u8 param) {
@@ -116,7 +117,7 @@ inline void J3DGDSetNumTexGens(u8 numTexGens) {
J3DGDWriteXFCmd(0x103f, numTexGens);
}
inline void J3DGDSetTevKonstantSel_SwapModeTable(GXTevStageID stage, GXTevKColorSel colorSel1, GXTevKAlphaSel alphaSel1, GXTevKColorSel colorSel2, GXTevKAlphaSel alphaSel2, GXTevColor chan1, GXTevColor chan2) {
inline void J3DGDSetTevKonstantSel_SwapModeTable(GXTevStageID stage, GXTevKColorSel colorSel1, GXTevKAlphaSel alphaSel1, GXTevKColorSel colorSel2, GXTevKAlphaSel alphaSel2, GXTevColorChan chan1, GXTevColorChan chan2) {
J3DGDWriteBPCmd((stage / 2 + 0xf6) << 24 | (chan1 | chan2 << 2 | colorSel1 << 4 | alphaSel1 << 9 | colorSel2 << 14 | alphaSel2 << 19) & 0x00FFFFFF);
}
+2 -2
View File
@@ -16,13 +16,13 @@ public:
};
static inline void J3DFifoWriteCPCmd(u8 cmd, u32 param) {
GXWGFifo.u8 = GX_CMD_LOAD_CP_REG;
GXWGFifo.u8 = GX_LOAD_CP_REG;
GXWGFifo.u8 = cmd;
GXWGFifo.u32 = param;
}
static inline void J3DFifoWriteXFCmd(u16 cmd, u16 len) {
GXWGFifo.u8 = GX_CMD_LOAD_XF_REG;
GXWGFifo.u8 = GX_LOAD_XF_REG;
GXWGFifo.u16 = (len - 1);
GXWGFifo.u16 = cmd;
}
+2 -2
View File
@@ -1,9 +1,9 @@
#ifndef J3DSTRUCT_H
#define J3DSTRUCT_H
#include "dolphin/gx/GXStruct.h"
#include <dolphin/gx.h>
#include "dolphin/mtx.h"
#include "dolphin/mtx.h"
#include "dolphin/mtx/vec.h"
/**
* @ingroup jsystem-j3d
+2 -1
View File
@@ -1,7 +1,8 @@
#ifndef J3DSYS_H
#define J3DSYS_H
#include "dolphin/gx.h"
#include <dolphin/gx.h>
#include <dolphin/mtx.h>
// Perhaps move to a new J3DEnum.h?
enum J3DError {
+1 -1
View File
@@ -2,7 +2,7 @@
#define J3DTEVS_H
#include "dolphin/types.h"
#include "dolphin/gx/GXStruct.h"
#include <dolphin/gx.h>
#include "JSystem/J3DGraphBase/J3DGD.h"
/**
+3 -3
View File
@@ -13,7 +13,7 @@ struct J3DTextureSRTInfo;
struct J3DTransformInfo {
/* 0x00 */ Vec mScale;
/* 0x0C */ SVec mRotation;
/* 0x0C */ S16Vec mRotation;
/* 0x14 */ Vec mTranslate;
/* inline J3DTransformInfo& operator=(const J3DTransformInfo& b) {
@@ -162,7 +162,7 @@ inline void J3DPSMulMtxVec(register MtxP mtx, register Vec* vec, register Vec* d
}
// regalloc issues
inline void J3DPSMulMtxVec(register MtxP mtx, register SVec* vec, register SVec* dst) {
inline void J3DPSMulMtxVec(register MtxP mtx, register S16Vec* vec, register S16Vec* dst) {
register f32 fr12;
register f32 fr11;
register f32 fr10;
@@ -252,7 +252,7 @@ inline void J3DPSMulMtxVec(register Mtx3P mtx, register Vec* vec, register Vec*
}
// regalloc issues
inline void J3DPSMulMtxVec(register Mtx3P mtx, register SVec* vec, register SVec* dst) {
inline void J3DPSMulMtxVec(register Mtx3P mtx, register S16Vec* vec, register S16Vec* dst) {
register f32* punit;
register f32 unit;
register f32 fr6;
+2 -2
View File
@@ -1,8 +1,8 @@
#ifndef J3DVERTEX_H
#define J3DVERTEX_H
#include "dolphin/gx/GXAttr.h"
#include "dolphin/mtx/vec.h"
#include <dolphin/gx.h>
#include "dolphin/mtx.h"
typedef struct _GXColor GXColor;
class J3DModel;