mirror of
https://github.com/zeldaret/oot.git
synced 2025-08-21 14:31:17 +00:00
Document undocumented matrix functions (#955)
* Document `func_800D1694` as `Matrix_TranslateRotateYXZ` * Document `func_800D1FD4` as `Matrix_ReplaceRotation` * Cleanup `Matrix_RotateAxis` * Document `func_800A7EC0` as `SkinMatrix_SetRotateAxis` * Document `func_800D2A34` and `func_800D2A98` as `Matrix_SetTranslateScaleMtx`(`F`) * Document mostly unused functions at the end of `sys_matrix.c` * Add in-use renamed functions to `namefixer.py` * Add `Matrix_SetTranslateScaleMtx2` to `namefixer.py` * Run formatter * Fix namefixer.py mistake from #952 * Format clang-11.1 * Fix `Matrix_TranslateRotateYXZ` wrongly documented, it actually is `Matrix_SetTranslateRotateYXZ` * VS Code is stellar at refactoring (no) * Run formatter * Come on VS Code * Improve `Matrix_ReplaceRotation` docs * Fix typo * Fix namefixer.py
This commit is contained in:
parent
0b8edc21c0
commit
b1d3844325
63 changed files with 403 additions and 374 deletions
|
@ -3324,7 +3324,7 @@ void func_80942180(BossTw* this, GlobalContext* globalCtx) {
|
|||
gDPSetEnvColor(POLY_XLU_DISP++, 255, 245, 255, 128);
|
||||
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(object_tw_DL_019D40));
|
||||
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_boss_tw.c", 6514),
|
||||
G_MTX_LOAD | G_MTX_MODELVIEW | G_MTX_NOPUSH);
|
||||
gSPSegment(POLY_XLU_DISP++, 8,
|
||||
|
@ -3396,7 +3396,7 @@ void func_809426F0(BossTw* this, GlobalContext* globalCtx) {
|
|||
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, ((this->work[CS_TIMER_2] * 3) + (i * 10)) & 0x7F,
|
||||
(u8)((-this->work[CS_TIMER_2] * 15) + (i * 50)), 0x20, 0x40, 1, 0, 0, 0x20, 0x20));
|
||||
Matrix_Scale(0.4f, 0.4f, 0.4f, MTXMODE_APPLY);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_boss_tw.c", 6751),
|
||||
G_MTX_LOAD | G_MTX_MODELVIEW | G_MTX_NOPUSH);
|
||||
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(object_tw_DL_01A430));
|
||||
|
@ -4461,7 +4461,7 @@ void BossTw_BlastDraw(Actor* thisx, GlobalContext* globalCtx2) {
|
|||
scaleFactor = 1.0f - (i * 0.09f);
|
||||
Matrix_Scale(this->actor.scale.x * scaleFactor, this->actor.scale.y * scaleFactor,
|
||||
this->actor.scale.z * scaleFactor, MTXMODE_APPLY);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_boss_tw.c", 8865),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(object_tw_DL_01A430));
|
||||
|
@ -4485,7 +4485,7 @@ void BossTw_BlastDraw(Actor* thisx, GlobalContext* globalCtx2) {
|
|||
scaleFactor = 1.0f - (i * 0.09f);
|
||||
Matrix_Scale(this->actor.scale.x * scaleFactor, this->actor.scale.y * scaleFactor,
|
||||
this->actor.scale.z * scaleFactor, MTXMODE_APPLY);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_boss_tw.c", 9004),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(object_tw_DL_01AB00));
|
||||
|
@ -4525,7 +4525,7 @@ void BossTw_DrawDeathBall(Actor* thisx, GlobalContext* globalCtx2) {
|
|||
scaleFactor = (1.0f - (i * 0.09f));
|
||||
Matrix_Scale(this->actor.scale.x * scaleFactor, this->actor.scale.y * scaleFactor,
|
||||
this->actor.scale.z * scaleFactor, MTXMODE_APPLY);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_boss_tw.c", 9071),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(object_tw_DL_01A430));
|
||||
|
@ -4545,7 +4545,7 @@ void BossTw_DrawDeathBall(Actor* thisx, GlobalContext* globalCtx2) {
|
|||
scaleFactor = (1.0f - (i * 0.09f));
|
||||
Matrix_Scale(this->actor.scale.x * scaleFactor, this->actor.scale.y * scaleFactor,
|
||||
this->actor.scale.z * scaleFactor, MTXMODE_APPLY);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(globalCtx->state.gfxCtx, "../z_boss_tw.c", 9107),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
gSPDisplayList(POLY_XLU_DISP++, SEGMENTED_TO_VIRTUAL(object_tw_DL_01AB00));
|
||||
|
@ -4922,7 +4922,7 @@ void BossTw_DrawEffects(GlobalContext* globalCtx) {
|
|||
gDPSetPrimColor(POLY_XLU_DISP++, 0, 0, currentEffect->color.r, currentEffect->color.g,
|
||||
currentEffect->color.b, currentEffect->alpha);
|
||||
Matrix_Translate(currentEffect->pos.x, currentEffect->pos.y, currentEffect->pos.z, MTXMODE_NEW);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
Matrix_Scale(currentEffect->workf[EFF_SCALE], currentEffect->workf[EFF_SCALE], 1.0f, MTXMODE_APPLY);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(gfxCtx, "../z_boss_tw.c", 9617),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
@ -4947,7 +4947,7 @@ void BossTw_DrawEffects(GlobalContext* globalCtx) {
|
|||
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, (currentEffect->frame * 3) & 0x7F,
|
||||
(currentEffect->frame * 15) & 0xFF, 0x20, 0x40, 1, 0, 0, 0x20, 0x20));
|
||||
Matrix_Translate(currentEffect->pos.x, currentEffect->pos.y, currentEffect->pos.z, MTXMODE_NEW);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
Matrix_Scale(currentEffect->workf[EFF_SCALE], currentEffect->workf[EFF_SCALE], 1.0f, MTXMODE_APPLY);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(gfxCtx, "../z_boss_tw.c", 9660),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
@ -4972,7 +4972,7 @@ void BossTw_DrawEffects(GlobalContext* globalCtx) {
|
|||
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, (currentEffect->frame * 3) & 0x7F,
|
||||
(currentEffect->frame * 15) & 0xFF, 0x20, 0x40, 1, 0, 0, 0x20, 0x20));
|
||||
Matrix_Translate(currentEffect->pos.x, currentEffect->pos.y, currentEffect->pos.z, MTXMODE_NEW);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
Matrix_Scale(currentEffect->workf[EFF_SCALE], currentEffect->workf[EFF_SCALE], 1.0f, MTXMODE_APPLY);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(gfxCtx, "../z_boss_tw.c", 9709),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
@ -5006,7 +5006,7 @@ void BossTw_DrawEffects(GlobalContext* globalCtx) {
|
|||
}
|
||||
|
||||
Matrix_Translate(currentEffect->pos.x, currentEffect->pos.y, currentEffect->pos.z, MTXMODE_NEW);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
|
||||
if (currentEffect->work[EFF_UNKS1] == 0) {
|
||||
Matrix_Translate(0.0f, 0.0f, 60.0f, MTXMODE_APPLY);
|
||||
|
@ -5091,7 +5091,7 @@ void BossTw_DrawEffects(GlobalContext* globalCtx) {
|
|||
Gfx_TwoTexScroll(globalCtx->state.gfxCtx, 0, (currentEffect->frame * 3) & 0x7F,
|
||||
(-currentEffect->frame * 15) & 0xFF, 0x20, 0x40, 1, 0, 0, 0x20, 0x20));
|
||||
Matrix_Translate(currentEffect->pos.x, currentEffect->pos.y, currentEffect->pos.z, MTXMODE_NEW);
|
||||
func_800D1FD4(&globalCtx->billboardMtxF);
|
||||
Matrix_ReplaceRotation(&globalCtx->billboardMtxF);
|
||||
Matrix_Scale(currentEffect->workf[EFF_SCALE], currentEffect->workf[EFF_SCALE], 1.0f, MTXMODE_APPLY);
|
||||
gSPMatrix(POLY_XLU_DISP++, Matrix_NewMtx(gfxCtx, "../z_boss_tw.c", 9911),
|
||||
G_MTX_NOPUSH | G_MTX_LOAD | G_MTX_MODELVIEW);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue