mirror of
https://github.com/zeldaret/oot.git
synced 2024-11-14 21:40:03 +00:00
[headers] gfx_setupdl.h and z64skin_matrix.h (#2221)
* [headers] gfx_setupdl.h and z64skin_matrix.h * include z64skin_matrix.h * bss * bss
This commit is contained in:
parent
dc1501e7a0
commit
a09ea76025
10 changed files with 155 additions and 130 deletions
|
@ -655,42 +655,7 @@ void PreNMI_Init(GameState* thisx);
|
|||
Gfx* Gfx_SetFog(Gfx* gfx, s32 r, s32 g, s32 b, s32 a, s32 near, s32 far);
|
||||
Gfx* Gfx_SetFogWithSync(Gfx* gfx, s32 r, s32 g, s32 b, s32 a, s32 near, s32 far);
|
||||
Gfx* Gfx_SetFog2(Gfx* gfx, s32 r, s32 g, s32 b, s32 a, s32 near, s32 far);
|
||||
Gfx* Gfx_SetupDL(Gfx* gfx, u32 i);
|
||||
Gfx* Gfx_SetupDL_57(Gfx* gfx);
|
||||
Gfx* Gfx_SetupDL_52NoCD(Gfx* gfx);
|
||||
void Gfx_SetupDL_57Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_51Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_54Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_26Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_25Xlu2(GraphicsContext* gfxCtx);
|
||||
void func_80093C80(PlayState* play);
|
||||
void Gfx_SetupDL_25Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_25Xlu(GraphicsContext* gfxCtx);
|
||||
Gfx* Gfx_SetupDL_64(Gfx* gfx);
|
||||
Gfx* Gfx_SetupDL_34(Gfx* gfx);
|
||||
void Gfx_SetupDL_44Xlu(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_36Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_28Opa(GraphicsContext* gfxCtx);
|
||||
Gfx* Gfx_SetupDL_28(Gfx* gfx);
|
||||
void Gfx_SetupDL_38Xlu(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_4Xlu(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_37Opa(GraphicsContext* gfxCtx);
|
||||
Gfx* Gfx_SetupDL_39(Gfx* gfx);
|
||||
void Gfx_SetupDL_39Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_39Overlay(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_39Ptr(Gfx** gfxP);
|
||||
void Gfx_SetupDL_40Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_41Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_47Xlu(GraphicsContext* gfxCtx);
|
||||
Gfx* Gfx_SetupDL_20NoCD(Gfx* gfx);
|
||||
Gfx* Gfx_SetupDL_66(Gfx* gfx);
|
||||
Gfx* func_800947AC(Gfx* gfx);
|
||||
void Gfx_SetupDL_42Opa(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_42Overlay(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_27Xlu(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_60NoCDXlu(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_61Xlu(GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_56Ptr(Gfx** gfxP);
|
||||
|
||||
Gfx* Gfx_BranchTexScroll(Gfx** gfxP, u32 x, u32 y, s32 width, s32 height);
|
||||
Gfx* func_80094E78(GraphicsContext* gfxCtx, u32 x, u32 y);
|
||||
Gfx* Gfx_TexScroll(GraphicsContext* gfxCtx, u32 x, u32 y, s32 width, s32 height);
|
||||
|
@ -738,21 +703,6 @@ void Skin_Init(PlayState* play, Skin* skin, SkeletonHeader* skeletonHeader, Anim
|
|||
void Skin_Free(PlayState* play, Skin* skin);
|
||||
s32 Skin_ApplyAnimTransformations(Skin* skin, MtxF* limbMatrices, Actor* actor, s32 setTranslation);
|
||||
|
||||
void SkinMatrix_Vec3fMtxFMultXYZW(MtxF* mf, Vec3f* src, Vec3f* xyzDest, f32* wDest);
|
||||
void SkinMatrix_Vec3fMtxFMultXYZ(MtxF* mf, Vec3f* src, Vec3f* dest);
|
||||
void SkinMatrix_MtxFMtxFMult(MtxF* mfA, MtxF* mfB, MtxF* dest);
|
||||
void SkinMatrix_GetClear(MtxF** mfp);
|
||||
void SkinMatrix_MtxFCopy(MtxF* src, MtxF* dest);
|
||||
s32 SkinMatrix_Invert(MtxF* src, MtxF* dest);
|
||||
void SkinMatrix_SetScale(MtxF* mf, f32 x, f32 y, f32 z);
|
||||
void SkinMatrix_SetRotateZYX(MtxF* mf, s16 x, s16 y, s16 z);
|
||||
void SkinMatrix_SetTranslate(MtxF* mf, f32 x, f32 y, f32 z);
|
||||
void SkinMatrix_SetTranslateRotateYXZScale(MtxF* dest, f32 scaleX, f32 scaleY, f32 scaleZ, s16 rotX, s16 rotY, s16 rotZ,
|
||||
f32 translateX, f32 translateY, f32 translateZ);
|
||||
void SkinMatrix_SetTranslateRotateZYX(MtxF* dest, s16 rotX, s16 rotY, s16 rotZ, f32 translateX, f32 translateY,
|
||||
f32 translateZ);
|
||||
Mtx* SkinMatrix_MtxFToNewMtx(GraphicsContext* gfxCtx, MtxF* src);
|
||||
void SkinMatrix_SetRotateAxis(MtxF* mf, s16 angle, f32 axisX, f32 axisY, f32 axisZ);
|
||||
void Sram_InitNewSave(void);
|
||||
void Sram_InitDebugSave(void);
|
||||
void Sram_OpenSave(SramContext* sramCtx);
|
||||
|
|
|
@ -51,81 +51,6 @@ typedef struct GraphicsContext {
|
|||
/* 0x02FC */ char unk_2FC[0x04];
|
||||
} GraphicsContext; // size = 0x300
|
||||
|
||||
typedef enum SetupDL {
|
||||
/* 0 */ SETUPDL_0,
|
||||
/* 1 */ SETUPDL_1,
|
||||
/* 2 */ SETUPDL_2,
|
||||
/* 3 */ SETUPDL_3,
|
||||
/* 4 */ SETUPDL_4,
|
||||
/* 5 */ SETUPDL_5,
|
||||
/* 6 */ SETUPDL_6,
|
||||
/* 7 */ SETUPDL_7,
|
||||
/* 8 */ SETUPDL_8,
|
||||
/* 9 */ SETUPDL_9,
|
||||
/* 10 */ SETUPDL_10,
|
||||
/* 11 */ SETUPDL_11,
|
||||
/* 12 */ SETUPDL_12,
|
||||
/* 13 */ SETUPDL_13,
|
||||
/* 14 */ SETUPDL_14,
|
||||
/* 15 */ SETUPDL_15,
|
||||
/* 16 */ SETUPDL_16,
|
||||
/* 17 */ SETUPDL_17,
|
||||
/* 18 */ SETUPDL_18,
|
||||
/* 19 */ SETUPDL_19,
|
||||
/* 20 */ SETUPDL_20,
|
||||
/* 21 */ SETUPDL_21,
|
||||
/* 22 */ SETUPDL_22,
|
||||
/* 23 */ SETUPDL_23,
|
||||
/* 24 */ SETUPDL_24,
|
||||
/* 25 */ SETUPDL_25,
|
||||
/* 26 */ SETUPDL_26,
|
||||
/* 27 */ SETUPDL_27,
|
||||
/* 28 */ SETUPDL_28,
|
||||
/* 29 */ SETUPDL_29,
|
||||
/* 30 */ SETUPDL_30,
|
||||
/* 31 */ SETUPDL_31,
|
||||
/* 32 */ SETUPDL_32,
|
||||
/* 33 */ SETUPDL_33,
|
||||
/* 34 */ SETUPDL_34,
|
||||
/* 35 */ SETUPDL_35,
|
||||
/* 36 */ SETUPDL_36,
|
||||
/* 37 */ SETUPDL_37,
|
||||
/* 38 */ SETUPDL_38,
|
||||
/* 39 */ SETUPDL_39,
|
||||
/* 40 */ SETUPDL_40,
|
||||
/* 41 */ SETUPDL_41,
|
||||
/* 42 */ SETUPDL_42,
|
||||
/* 43 */ SETUPDL_43,
|
||||
/* 44 */ SETUPDL_44,
|
||||
/* 45 */ SETUPDL_45,
|
||||
/* 46 */ SETUPDL_46,
|
||||
/* 47 */ SETUPDL_47,
|
||||
/* 48 */ SETUPDL_48,
|
||||
/* 49 */ SETUPDL_49,
|
||||
/* 50 */ SETUPDL_50,
|
||||
/* 51 */ SETUPDL_51,
|
||||
/* 52 */ SETUPDL_52,
|
||||
/* 53 */ SETUPDL_53,
|
||||
/* 54 */ SETUPDL_54,
|
||||
/* 55 */ SETUPDL_55,
|
||||
/* 56 */ SETUPDL_56,
|
||||
/* 57 */ SETUPDL_57,
|
||||
/* 58 */ SETUPDL_58,
|
||||
/* 59 */ SETUPDL_59,
|
||||
/* 60 */ SETUPDL_60,
|
||||
/* 61 */ SETUPDL_61,
|
||||
/* 62 */ SETUPDL_62,
|
||||
/* 63 */ SETUPDL_63,
|
||||
/* 64 */ SETUPDL_64,
|
||||
/* 65 */ SETUPDL_65,
|
||||
/* 66 */ SETUPDL_66,
|
||||
/* 67 */ SETUPDL_67,
|
||||
/* 68 */ SETUPDL_68,
|
||||
/* 69 */ SETUPDL_69,
|
||||
/* 70 */ SETUPDL_70,
|
||||
/* 71 */ SETUPDL_MAX
|
||||
} SetupDL;
|
||||
|
||||
void* Graph_Alloc(GraphicsContext* gfxCtx, size_t size);
|
||||
void* Graph_Alloc2(GraphicsContext* gfxCtx, size_t size);
|
||||
|
||||
|
|
121
include/gfx_setupdl.h
Normal file
121
include/gfx_setupdl.h
Normal file
|
@ -0,0 +1,121 @@
|
|||
#ifndef GFX_SETUPDL_H
|
||||
#define GFX_SETUPDL_H
|
||||
|
||||
#include "ultra64.h"
|
||||
|
||||
struct GraphicsContext;
|
||||
struct PlayState;
|
||||
|
||||
typedef enum SetupDL {
|
||||
/* 0 */ SETUPDL_0,
|
||||
/* 1 */ SETUPDL_1,
|
||||
/* 2 */ SETUPDL_2,
|
||||
/* 3 */ SETUPDL_3,
|
||||
/* 4 */ SETUPDL_4,
|
||||
/* 5 */ SETUPDL_5,
|
||||
/* 6 */ SETUPDL_6,
|
||||
/* 7 */ SETUPDL_7,
|
||||
/* 8 */ SETUPDL_8,
|
||||
/* 9 */ SETUPDL_9,
|
||||
/* 10 */ SETUPDL_10,
|
||||
/* 11 */ SETUPDL_11,
|
||||
/* 12 */ SETUPDL_12,
|
||||
/* 13 */ SETUPDL_13,
|
||||
/* 14 */ SETUPDL_14,
|
||||
/* 15 */ SETUPDL_15,
|
||||
/* 16 */ SETUPDL_16,
|
||||
/* 17 */ SETUPDL_17,
|
||||
/* 18 */ SETUPDL_18,
|
||||
/* 19 */ SETUPDL_19,
|
||||
/* 20 */ SETUPDL_20,
|
||||
/* 21 */ SETUPDL_21,
|
||||
/* 22 */ SETUPDL_22,
|
||||
/* 23 */ SETUPDL_23,
|
||||
/* 24 */ SETUPDL_24,
|
||||
/* 25 */ SETUPDL_25,
|
||||
/* 26 */ SETUPDL_26,
|
||||
/* 27 */ SETUPDL_27,
|
||||
/* 28 */ SETUPDL_28,
|
||||
/* 29 */ SETUPDL_29,
|
||||
/* 30 */ SETUPDL_30,
|
||||
/* 31 */ SETUPDL_31,
|
||||
/* 32 */ SETUPDL_32,
|
||||
/* 33 */ SETUPDL_33,
|
||||
/* 34 */ SETUPDL_34,
|
||||
/* 35 */ SETUPDL_35,
|
||||
/* 36 */ SETUPDL_36,
|
||||
/* 37 */ SETUPDL_37,
|
||||
/* 38 */ SETUPDL_38,
|
||||
/* 39 */ SETUPDL_39,
|
||||
/* 40 */ SETUPDL_40,
|
||||
/* 41 */ SETUPDL_41,
|
||||
/* 42 */ SETUPDL_42,
|
||||
/* 43 */ SETUPDL_43,
|
||||
/* 44 */ SETUPDL_44,
|
||||
/* 45 */ SETUPDL_45,
|
||||
/* 46 */ SETUPDL_46,
|
||||
/* 47 */ SETUPDL_47,
|
||||
/* 48 */ SETUPDL_48,
|
||||
/* 49 */ SETUPDL_49,
|
||||
/* 50 */ SETUPDL_50,
|
||||
/* 51 */ SETUPDL_51,
|
||||
/* 52 */ SETUPDL_52,
|
||||
/* 53 */ SETUPDL_53,
|
||||
/* 54 */ SETUPDL_54,
|
||||
/* 55 */ SETUPDL_55,
|
||||
/* 56 */ SETUPDL_56,
|
||||
/* 57 */ SETUPDL_57,
|
||||
/* 58 */ SETUPDL_58,
|
||||
/* 59 */ SETUPDL_59,
|
||||
/* 60 */ SETUPDL_60,
|
||||
/* 61 */ SETUPDL_61,
|
||||
/* 62 */ SETUPDL_62,
|
||||
/* 63 */ SETUPDL_63,
|
||||
/* 64 */ SETUPDL_64,
|
||||
/* 65 */ SETUPDL_65,
|
||||
/* 66 */ SETUPDL_66,
|
||||
/* 67 */ SETUPDL_67,
|
||||
/* 68 */ SETUPDL_68,
|
||||
/* 69 */ SETUPDL_69,
|
||||
/* 70 */ SETUPDL_70,
|
||||
/* 71 */ SETUPDL_MAX
|
||||
} SetupDL;
|
||||
|
||||
Gfx* Gfx_SetupDL(Gfx* gfx, u32 i);
|
||||
Gfx* Gfx_SetupDL_57(Gfx* gfx);
|
||||
Gfx* Gfx_SetupDL_52NoCD(Gfx* gfx);
|
||||
void Gfx_SetupDL_57Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_51Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_54Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_26Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_25Xlu2(struct GraphicsContext* gfxCtx);
|
||||
void func_80093C80(struct PlayState* play);
|
||||
void Gfx_SetupDL_25Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_25Xlu(struct GraphicsContext* gfxCtx);
|
||||
Gfx* Gfx_SetupDL_64(Gfx* gfx);
|
||||
Gfx* Gfx_SetupDL_34(Gfx* gfx);
|
||||
void Gfx_SetupDL_44Xlu(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_36Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_28Opa(struct GraphicsContext* gfxCtx);
|
||||
Gfx* Gfx_SetupDL_28(Gfx* gfx);
|
||||
void Gfx_SetupDL_38Xlu(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_4Xlu(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_37Opa(struct GraphicsContext* gfxCtx);
|
||||
Gfx* Gfx_SetupDL_39(Gfx* gfx);
|
||||
void Gfx_SetupDL_39Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_39Overlay(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_39Ptr(Gfx** gfxP);
|
||||
void Gfx_SetupDL_40Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_41Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_47Xlu(struct GraphicsContext* gfxCtx);
|
||||
Gfx* Gfx_SetupDL_20NoCD(Gfx* gfx);
|
||||
Gfx* Gfx_SetupDL_66(Gfx* gfx);
|
||||
Gfx* func_800947AC(Gfx* gfx);
|
||||
void Gfx_SetupDL_42Opa(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_42Overlay(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_27Xlu(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_60NoCDXlu(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_61Xlu(struct GraphicsContext* gfxCtx);
|
||||
void Gfx_SetupDL_56Ptr(Gfx** gfxP);
|
||||
|
||||
#endif
|
|
@ -34,6 +34,7 @@
|
|||
#include "z64pause.h"
|
||||
#include "z64play.h"
|
||||
#include "z64skin.h"
|
||||
#include "z64skin_matrix.h"
|
||||
#include "z64game.h"
|
||||
#include "z64transition.h"
|
||||
#include "z64transition_instances.h"
|
||||
|
@ -62,6 +63,7 @@
|
|||
#include "thga.h"
|
||||
#include "speedmeter.h"
|
||||
#include "gfx.h"
|
||||
#include "gfx_setupdl.h"
|
||||
#include "jpeg.h"
|
||||
#include "prerender.h"
|
||||
#include "rand.h"
|
||||
|
|
25
include/z64skin_matrix.h
Normal file
25
include/z64skin_matrix.h
Normal file
|
@ -0,0 +1,25 @@
|
|||
#ifndef Z64SKIN_MATRIX_H
|
||||
#define Z64SKIN_MATRIX_H
|
||||
|
||||
#include "ultra64.h"
|
||||
#include "z64math.h"
|
||||
|
||||
struct GraphicsContext;
|
||||
|
||||
void SkinMatrix_Vec3fMtxFMultXYZW(MtxF* mf, Vec3f* src, Vec3f* xyzDest, f32* wDest);
|
||||
void SkinMatrix_Vec3fMtxFMultXYZ(MtxF* mf, Vec3f* src, Vec3f* dest);
|
||||
void SkinMatrix_MtxFMtxFMult(MtxF* mfA, MtxF* mfB, MtxF* dest);
|
||||
void SkinMatrix_GetClear(MtxF** mfp);
|
||||
void SkinMatrix_MtxFCopy(MtxF* src, MtxF* dest);
|
||||
s32 SkinMatrix_Invert(MtxF* src, MtxF* dest);
|
||||
void SkinMatrix_SetScale(MtxF* mf, f32 x, f32 y, f32 z);
|
||||
void SkinMatrix_SetRotateZYX(MtxF* mf, s16 x, s16 y, s16 z);
|
||||
void SkinMatrix_SetTranslate(MtxF* mf, f32 x, f32 y, f32 z);
|
||||
void SkinMatrix_SetTranslateRotateYXZScale(MtxF* dest, f32 scaleX, f32 scaleY, f32 scaleZ, s16 rotX, s16 rotY, s16 rotZ,
|
||||
f32 translateX, f32 translateY, f32 translateZ);
|
||||
void SkinMatrix_SetTranslateRotateZYX(MtxF* dest, s16 rotX, s16 rotY, s16 rotZ, f32 translateX, f32 translateY,
|
||||
f32 translateZ);
|
||||
Mtx* SkinMatrix_MtxFToNewMtx(struct GraphicsContext* gfxCtx, MtxF* src);
|
||||
void SkinMatrix_SetRotateAxis(MtxF* mf, s16 angle, f32 axisX, f32 axisY, f32 axisZ);
|
||||
|
||||
#endif
|
|
@ -27,7 +27,7 @@
|
|||
#endif
|
||||
|
||||
#pragma increment_block_number "gc-eu:128 gc-eu-mq:128 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128" \
|
||||
"ntsc-1.2:108"
|
||||
"ntsc-1.2:106"
|
||||
|
||||
StackEntry sDmaMgrStackInfo;
|
||||
OSMesgQueue sDmaMgrMsgQueue;
|
||||
|
|
|
@ -23,7 +23,7 @@ extern struct IrqMgr gIrqMgr;
|
|||
#endif
|
||||
|
||||
#pragma increment_block_number "gc-eu:192 gc-eu-mq:192 gc-jp:192 gc-jp-ce:192 gc-jp-mq:192 gc-us:192 gc-us-mq:192" \
|
||||
"ntsc-1.2:166"
|
||||
"ntsc-1.2:164"
|
||||
|
||||
extern u8 _buffersSegmentEnd[];
|
||||
|
||||
|
|
|
@ -3638,7 +3638,7 @@ s32 Camera_KeepOn3(Camera* camera) {
|
|||
}
|
||||
|
||||
#pragma increment_block_number "gc-eu:128 gc-eu-mq:128 gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128" \
|
||||
"ntsc-1.2:110"
|
||||
"ntsc-1.2:108"
|
||||
|
||||
s32 Camera_KeepOn4(Camera* camera) {
|
||||
static Vec3f D_8015BD50;
|
||||
|
|
|
@ -142,6 +142,8 @@ static EnPoFieldInfo sPoFieldInfo[2] = {
|
|||
|
||||
static Vec3f D_80AD714C = { 0.0f, 1400.0f, 0.0f };
|
||||
|
||||
#pragma increment_block_number "gc-jp:128 gc-jp-ce:128 gc-jp-mq:128 gc-us:128 gc-us-mq:128 ntsc-1.2:128"
|
||||
|
||||
static Vec3s sSpawnPositions[10];
|
||||
static u8 sSpawnSwitchFlags[10];
|
||||
static MtxF sLimb7Mtx;
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
#include "cic6105.h"
|
||||
#endif
|
||||
|
||||
#pragma increment_block_number "gc-eu:131 gc-eu-mq:131 gc-jp:133 gc-jp-ce:133 gc-jp-mq:133 gc-us:133 gc-us-mq:133"
|
||||
#pragma increment_block_number "gc-eu:129 gc-eu-mq:129 gc-jp:131 gc-jp-ce:131 gc-jp-mq:131 gc-us:131 gc-us-mq:131"
|
||||
|
||||
#define FLAGS ACTOR_FLAG_4
|
||||
|
||||
|
|
Loading…
Reference in a new issue