Skip to content

Commit

Permalink
get soh working with latest lus (#4132)
Browse files Browse the repository at this point in the history
  • Loading branch information
briaguya-ai authored May 8, 2024
1 parent 52fad95 commit 0976198
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 98 deletions.
2 changes: 0 additions & 2 deletions soh/include/functions.h
Original file line number Diff line number Diff line change
Expand Up @@ -2354,7 +2354,6 @@ s32 __osCheckPackId(OSPfs* pfs, __OSPackId* check);
s32 __osGetId(OSPfs* pfs);
s32 __osCheckId(OSPfs* pfs);
s32 __osPfsRWInode(OSPfs* pfs, __OSInode* inode, u8 flag, u8 bank);
void guMtxL2F(MtxF* m1, Mtx* m2);
s32 osPfsFindFile(OSPfs* pfs, u16 companyCode, u32 gameCode, u8* gameName, u8* extName, s32* fileNo);
s32 osAfterPreNMI(void);
s32 osContStartQuery(OSMesgQueue* mq);
Expand Down Expand Up @@ -2408,7 +2407,6 @@ u32 __osSpGetStatus(void);
void __osSpSetStatus(u32 status);
void osWritebackDCacheAll(void);
OSThread* __osGetCurrFaultedThread(void);
void guMtxF2L(MtxF* m1, Mtx* m2);
// ? __d_to_ll(?);
// ? __f_to_ll(?);
// ? __d_to_ull(?);
Expand Down
6 changes: 3 additions & 3 deletions soh/soh/Enhancements/debugger/colViewer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ void DrawBgActorCollision() {
bg.curTransform.scale.z, bg.curTransform.rot.x, bg.curTransform.rot.y,
bg.curTransform.rot.z, bg.curTransform.pos.x, bg.curTransform.pos.y,
bg.curTransform.pos.z);
guMtxF2L(&mf, &m);
// guMtxF2L(mf, &m);
mtxDl.push_back(m);
dl.push_back(gsSPMatrix(&mtxDl.back(), G_MTX_MODELVIEW | G_MTX_LOAD | G_MTX_PUSH));

Expand Down Expand Up @@ -493,7 +493,7 @@ void DrawColCheckList(std::vector<Gfx>& dl, Collider** objects, int32_t count) {
SkinMatrix_SetScale(&ms, radius / 128.0f, radius / 128.0f, radius / 128.0f);
MtxF dest;
SkinMatrix_MtxFMtxFMult(&mf, &ms, &dest);
guMtxF2L(&dest, &m);
// guMtxF2L(&dest, &m);
mtxDl.push_back(m);

dl.push_back(gsSPMatrix(&mtxDl.back(), G_MTX_MODELVIEW | G_MTX_LOAD | G_MTX_PUSH));
Expand All @@ -512,7 +512,7 @@ void DrawColCheckList(std::vector<Gfx>& dl, Collider** objects, int32_t count) {
SkinMatrix_SetScale(&ms, radius / 128.0f, cyl->dim.height / 128.0f, radius / 128.0f);
MtxF dest;
SkinMatrix_MtxFMtxFMult(&mt, &ms, &dest);
guMtxF2L(&dest, &m);
// guMtxF2L(&dest, &m);
mtxDl.push_back(m);

dl.push_back(gsSPMatrix(&mtxDl.back(), G_MTX_MODELVIEW | G_MTX_LOAD | G_MTX_PUSH));
Expand Down
93 changes: 1 addition & 92 deletions soh/soh/stubs.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#include <libultraship/libultra.h>
#include <stdarg.h>
#include <stdio.h>
#include <string.h>
#include "z64.h"
Expand Down Expand Up @@ -31,18 +32,6 @@ f32 qNaN0x10000 = 0x7F810000;
// __gSPTextureRectangle(pkt, xl, yl, xh, yh, tile, s, t, dsdx, dtdy);
//}

s32 osJamMesg(OSMesgQueue* mq, OSMesg msg, s32 flag)
{
}

void osSetEventMesg(OSEvent e, OSMesgQueue* mq, OSMesg msg)
{
}

void osViSetEvent(OSMesgQueue* mq, OSMesg msg, u32 retraceCount)
{
}

OSId osGetThreadId(OSThread* thread)
{
}
Expand All @@ -55,31 +44,11 @@ void osSetThreadPri(OSThread* thread, OSPri pri)
{
}

s32 osSetTimer(OSTimer* timer, OSTime countdown, OSTime interval, OSMesgQueue* mq, OSMesg msg)
{

}

void osCreatePiManager(OSPri pri, OSMesgQueue* cmdQ, OSMesg* cmdBuf, s32 cmdMsgCnt)
{

}

void osCreateViManager(OSPri pri)
{

}

s32 osMotorInit(OSMesgQueue* ctrlrqueue, OSPfs* pfs, s32 channel)
{
return 0;
}

u32 osAiGetLength(void)
{

}

s32 osPfsFreeBlocks(OSPfs* pfs, s32* leftoverBytes)
{

Expand Down Expand Up @@ -130,16 +99,6 @@ s32 osPfsAllocateFile(OSPfs* pfs, u16 companyCode, u32 gameCode, u8* gameName, u

}

s32 osAiSetNextBuffer(void* buf, size_t size)
{

}

s32 __osMotorAccess(OSPfs* pfs, u32 vibrate)
{

}

OSIntMask osSetIntMask(OSIntMask a)
{
return 0;
Expand Down Expand Up @@ -200,16 +159,6 @@ void osContGetQuery(OSContStatus* data)

}

void osViSwapBuffer(void* vaddr)
{

}

void* osViGetNextFramebuffer()
{

}

u32 __osGetFpcCsr()
{
return 0;
Expand Down Expand Up @@ -240,11 +189,6 @@ OSThread* __osGetCurrFaultedThread(void)

}

void osCartRomInit()
{

}

u32 osMemSize = 1024 * 1024 * 1024;

void Audio_osInvalDCache(void* buf, s32 size)
Expand All @@ -263,11 +207,6 @@ s32 osAiSetFrequency(u32 freq)
return 1;
}

s32 osEPiStartDma(OSPiHandle* handle, OSIoMesg* mb, s32 direction)
{

}

void osInvalDCache(void* vaddr, s32 nbytes)
{

Expand Down Expand Up @@ -313,31 +252,6 @@ OSPiHandle* osDriveRomInit()

}

void osViSetMode(OSViMode* mode)
{

}

void osViBlack(u8 active)
{

}

void osViSetYScale(f32 scale)
{

}

void osViSetXScale(f32 value)
{

}

void osViSetSpecialFeatures(u32 func)
{

}

void __osInitialize_common(void)
{

Expand Down Expand Up @@ -390,11 +304,6 @@ s32 osEPiReadIo(OSPiHandle* handle, u32 devAddr, u32* data)
return 0;
}

u32* osViGetCurrentFramebuffer(void)
{

}

void osSpTaskYield(void)
{
}
Expand Down

0 comments on commit 0976198

Please sign in to comment.