J3DSys: j3dDefaultTexCoordInfo table

This commit is contained in:
Jasper St. Pierre 2022-04-23 15:46:00 -07:00
parent 5e47481d7f
commit d97594ac22
3 changed files with 23 additions and 17 deletions

View File

@ -67,4 +67,11 @@ struct J3DTexCoord : public J3DTexCoordInfo {
/* 0x4 */ u16 mTexMtxReg;
}; // Size: 0x6
struct J3DDefaultTexCoordInfo {
/* 0x0 */ u8 mTexGenType;
/* 0x1 */ u8 mTexGenSrc;
/* 0x2 */ u8 mTexGenMtx;
/* 0x3 */ u8 pad;
};
#endif /* J3DTEXTURE_H */

View File

@ -4,10 +4,13 @@
//
#include "JSystem/J3DGraphBase/J3DSys.h"
#include "dol2asm.h"
#include "dolphin/gx/GXPixel.h"
#include "dolphin/types.h"
#include "JSystem/J3DGraphBase/J3DTexture.h"
//
// Forward References:
//
@ -48,12 +51,12 @@ extern "C" void _savegpr_25();
extern "C" void _savegpr_28();
extern "C" void _restgpr_25();
extern "C" void _restgpr_28();
extern "C" extern u8 const j3dDefaultTexCoordInfo[32];
extern "C" extern GXColor j3dDefaultColInfo;
extern "C" extern J3DDefaultTexCoordInfo const j3dDefaultTexCoordInfo[8];
extern "C" extern const GXColor j3dDefaultColInfo;
extern "C" extern u8 data_804563C8;
extern "C" extern u32 j3dDefaultTevColor;
extern "C" extern u32 data_804563D8;
extern "C" extern GXColor j3dDefaultTevKColor;
extern "C" extern const GXColor j3dDefaultTevKColor;
//
// Declarations:

View File

@ -5,6 +5,7 @@
#include "JSystem/J3DGraphBase/J3DTevs.h"
#include "JSystem/J3DGraphBase/J3DSys.h"
#include "JSystem/J3DGraphBase/J3DTexture.h"
#include "dol2asm.h"
#include "dolphin/types.h"
@ -12,17 +13,6 @@
// Types:
//
struct J3DTexMtx {
/* 803238C4 */ void load(u32) const;
/* 80323900 */ void calc(f32 const (*)[4]);
/* 80323920 */ void calcTexMtx(f32 const (*)[4]);
/* 80323C0C */ void calcPostTexMtx(f32 const (*)[4]);
/* 80324358 */ void loadTexMtx(u32) const;
/* 803243BC */ void loadPostTexMtx(u32) const;
};
struct J3DTexCoord {};
struct J3DNBTScale {};
struct J3DLightObj {
@ -287,9 +277,15 @@ SECTION_RODATA extern u8 const j3dDefaultLightInfo[52] = {
COMPILER_STRIP_GATE(0x803A1EC8, &j3dDefaultLightInfo);
/* 803A1EFC-803A1F1C 02E55C 0020+00 0/0 5/5 0/0 .rodata j3dDefaultTexCoordInfo */
SECTION_RODATA extern u8 const j3dDefaultTexCoordInfo[32] = {
0x01, 0x04, 0x3C, 0x00, 0x01, 0x05, 0x3C, 0x00, 0x01, 0x06, 0x3C, 0x00, 0x01, 0x07, 0x3C, 0x00,
0x01, 0x08, 0x3C, 0x00, 0x01, 0x09, 0x3C, 0x00, 0x01, 0x0A, 0x3C, 0x00, 0x01, 0x0B, 0x3C, 0x00,
SECTION_RODATA extern J3DDefaultTexCoordInfo const j3dDefaultTexCoordInfo[8] = {
{ GX_MTX2x4, GX_TG_TEX0, GX_IDENTITY, 0 },
{ GX_MTX2x4, GX_TG_TEX1, GX_IDENTITY, 0 },
{ GX_MTX2x4, GX_TG_TEX2, GX_IDENTITY, 0 },
{ GX_MTX2x4, GX_TG_TEX3, GX_IDENTITY, 0 },
{ GX_MTX2x4, GX_TG_TEX4, GX_IDENTITY, 0 },
{ GX_MTX2x4, GX_TG_TEX5, GX_IDENTITY, 0 },
{ GX_MTX2x4, GX_TG_TEX6, GX_IDENTITY, 0 },
{ GX_MTX2x4, GX_TG_TEX7, GX_IDENTITY, 0 },
};
COMPILER_STRIP_GATE(0x803A1EFC, &j3dDefaultTexCoordInfo);