1
0
Fork 0
mirror of https://github.com/zeldaret/oot.git synced 2024-11-25 01:34:18 +00:00

Update clang-tidy configuration in format.sh and apply fixes for a new check (#1257)

* Update format.sh compiler options and add a check for clang-tidy

* Enable clang-tidy option to find inconsistent argument names

* Remove -Iassets from clang-tidy compiler options
This commit is contained in:
Roman971 2022-06-07 06:34:28 +02:00 committed by GitHub
parent 6f0b8f1e74
commit 04ade9a255
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 131 additions and 128 deletions

View file

@ -1,4 +1,4 @@
Checks: '-*,readability-braces-around-statements'
Checks: '-*,readability-braces-around-statements,readability-inconsistent-declaration-parameter-name'
WarningsAsErrors: ''
HeaderFilterRegex: '(src|include)\/.*\.h$'
FormatStyle: 'file'

View file

@ -3,7 +3,7 @@
FORMAT_VER="11"
FORMAT_OPTS="-i -style=file"
TIDY_OPTS="-p . --fix --fix-errors"
COMPILER_OPTS="-fno-builtin -std=gnu90 -Iinclude -Isrc -D_LANGUAGE_C -DNON_MATCHING"
COMPILER_OPTS="-fno-builtin -fsyntax-only -std=gnu90 -Iinclude -Isrc -Ibuild -I. -D_LANGUAGE_C -DNON_MATCHING"
# https://backreference.org/2010/05/23/sanitizing-files-with-no-trailing-newline/index.html
# "gets the last character of the file pipes it into read, which will exit with
@ -34,6 +34,12 @@ else
fi
fi
if [ ! $(command -v clang-tidy) ]
then
echo "clang-tidy not found. Exiting."
exit 1
fi
if (( $# > 0 )); then
echo "Formatting file(s) $*"
echo "Running clang-format..."

View file

@ -12,7 +12,7 @@ f32 fabsf(f32 f);
#endif
f32 sqrtf(f32 f);
#pragma intrinsic(sqrtf)
f64 sqrt(f64 d);
f64 sqrt(f64 f);
#pragma intrinsic(sqrt)
void cleararena(void);
@ -314,10 +314,8 @@ void EffectSsFireTail_Spawn(PlayState* play, Actor* actor, Vec3f* pos, f32 scale
void EffectSsFireTail_SpawnFlame(PlayState* play, Actor* actor, Vec3f* pos, f32 arg3, s16 bodyPart,
f32 colorIntensity);
void EffectSsFireTail_SpawnFlameOnPlayer(PlayState* play, f32 scale, s16 bodyPart, f32 colorIntensity);
void EffectSsEnFire_SpawnVec3f(PlayState* play, Actor* actor, Vec3f* pos, s16 scale, s16 unk_12, s16 flags,
s16 bodyPart);
void EffectSsEnFire_SpawnVec3s(PlayState* play, Actor* actor, Vec3s* vec, s16 scale, s16 arg4, s16 flags,
s16 bodyPart);
void EffectSsEnFire_SpawnVec3f(PlayState* play, Actor* actor, Vec3f* pos, s16 scale, s16 arg4, s16 flags, s16 bodyPart);
void EffectSsEnFire_SpawnVec3s(PlayState* play, Actor* actor, Vec3s* pos, s16 scale, s16 arg4, s16 flags, s16 bodyPart);
void EffectSsExtra_Spawn(PlayState* play, Vec3f* pos, Vec3f* velocity, Vec3f* accel, s16 scale, s16 scoreIdx);
void EffectSsFCircle_Spawn(PlayState* play, Actor* actor, Vec3f* pos, s16 radius, s16 height);
void EffectSsDeadDb_Spawn(PlayState* play, Vec3f* pos, Vec3f* velocity, Vec3f* accel, s16 scale, s16 scaleStep,
@ -417,8 +415,8 @@ Hilite* func_8002EABC(Vec3f* object, Vec3f* eye, Vec3f* lightDir, GraphicsContex
Hilite* func_8002EB44(Vec3f* object, Vec3f* eye, Vec3f* lightDir, GraphicsContext* gfxCtx);
void func_8002EBCC(Actor* actor, PlayState* play, s32 flag);
void func_8002ED80(Actor* actor, PlayState* play, s32 flag);
PosRot* Actor_GetFocus(PosRot* arg0, Actor* actor);
PosRot* Actor_GetWorld(PosRot* arg0, Actor* actor);
PosRot* Actor_GetFocus(PosRot* dest, Actor* actor);
PosRot* Actor_GetWorld(PosRot* dest, Actor* actor);
PosRot* Actor_GetWorldPosShapeRot(PosRot* arg0, Actor* actor);
s32 func_8002F0C8(Actor* actor, Player* player, s32 flag);
u32 Actor_ProcessTalkRequest(Actor* actor, PlayState* play);
@ -694,7 +692,7 @@ s32 Camera_CheckValidMode(Camera* camera, s16 mode);
s32 Camera_ChangeSetting(Camera* camera, s16 setting);
s32 Camera_ChangeDataIdx(Camera* camera, s32 camDataIdx);
s16 Camera_GetInputDirYaw(Camera* camera);
Vec3s* Camera_GetCamDir(Vec3s* dir, Camera* camera);
Vec3s* Camera_GetCamDir(Vec3s* dst, Camera* camera);
s16 Camera_GetCamDirPitch(Camera* camera);
s16 Camera_GetCamDirYaw(Camera* camera);
s32 Camera_AddQuake(Camera* camera, s32 arg1, s16 y, s32 countdown);
@ -791,7 +789,7 @@ void Collider_UpdateCylinder(Actor* actor, ColliderCylinder* collider);
void Collider_SetCylinderPosition(ColliderCylinder* collider, Vec3s* pos);
void Collider_SetQuadVertices(ColliderQuad* collider, Vec3f* a, Vec3f* b, Vec3f* c, Vec3f* d);
void Collider_SetTrisVertices(ColliderTris* collider, s32 index, Vec3f* a, Vec3f* b, Vec3f* c);
void Collider_SetTrisDim(PlayState* play, ColliderTris* collider, s32 index, ColliderTrisElementDimInit* init);
void Collider_SetTrisDim(PlayState* play, ColliderTris* collider, s32 index, ColliderTrisElementDimInit* src);
void Collider_UpdateSpheres(s32 limb, ColliderJntSph* collider);
void CollisionCheck_SpawnRedBlood(PlayState* play, Vec3f* v);
void CollisionCheck_SpawnWaterDroplets(PlayState* play, Vec3f* v);
@ -918,7 +916,7 @@ f32 Math_Vec3f_DistXYZAndStoreDiff(Vec3f* a, Vec3f* b, Vec3f* dest);
f32 Math_Vec3f_DistXZ(Vec3f* a, Vec3f* b);
s16 Math_Vec3f_Yaw(Vec3f* a, Vec3f* b);
s16 Math_Vec3f_Pitch(Vec3f* a, Vec3f* b);
void Actor_ProcessInitChain(Actor* actor, InitChainEntry* initChain);
void Actor_ProcessInitChain(Actor* actor, InitChainEntry* ichain);
f32 Math_SmoothStepToF(f32* pValue, f32 target, f32 fraction, f32 step, f32 minStep);
void Math_ApproachF(f32* pValue, f32 target, f32 fraction, f32 step);
void Math_ApproachZeroF(f32* pValue, f32 fraction, f32 step);
@ -985,8 +983,8 @@ f32 OLib_ClampMaxDist(f32 val, f32 max);
Vec3f* OLib_Vec3fDistNormalize(Vec3f* dest, Vec3f* a, Vec3f* b);
Vec3f* OLib_VecSphGeoToVec3f(Vec3f* dest, VecSph* sph);
VecSph* OLib_Vec3fToVecSph(VecSph* dest, Vec3f* vec);
VecSph* OLib_Vec3fToVecSphGeo(VecSph* arg0, Vec3f* arg1);
VecSph* OLib_Vec3fDiffToVecSphGeo(VecSph* arg0, Vec3f* a, Vec3f* b);
VecSph* OLib_Vec3fToVecSphGeo(VecSph* dest, Vec3f* vec);
VecSph* OLib_Vec3fDiffToVecSphGeo(VecSph* dest, Vec3f* a, Vec3f* b);
Vec3f* OLib_Vec3fDiffRad(Vec3f* dest, Vec3f* a, Vec3f* b);
s16 OnePointCutscene_Init(PlayState* play, s16 csId, s16 timer, Actor* actor, s16 camId);
s16 OnePointCutscene_EndCutscene(PlayState* play, s16 camId);
@ -1039,56 +1037,55 @@ f32 Path_OrientAndGetDistSq(Actor* actor, Path* path, s16 waypoint, s16* yaw);
void Path_CopyLastPoint(Path* path, Vec3f* dest);
void FrameAdvance_Init(FrameAdvanceContext* frameAdvCtx);
s32 FrameAdvance_Update(FrameAdvanceContext* frameAdvCtx, Input* input);
void Player_SetBootData(PlayState* play, Player* player);
s32 Player_InBlockingCsMode(PlayState* play, Player* player);
void Player_SetBootData(PlayState* play, Player* this);
s32 Player_InBlockingCsMode(PlayState* play, Player* this);
s32 Player_InCsMode(PlayState* play);
s32 func_8008E9C4(Player* player);
s32 Player_IsChildWithHylianShield(Player* player);
s32 Player_ActionToModelGroup(Player* player, s32 actionParam);
void Player_SetModelsForHoldingShield(Player* player);
void Player_SetModels(Player* player, s32 modelGroup);
void Player_SetModelGroup(Player* player, s32 modelGroup);
void func_8008EC70(Player* player);
void Player_SetEquipmentData(PlayState* play, Player* player);
void Player_UpdateBottleHeld(PlayState* play, Player* player, s32 item, s32 actionParam);
void func_8008EDF0(Player* player);
void func_8008EE08(Player* player);
s32 func_8008E9C4(Player* this);
s32 Player_IsChildWithHylianShield(Player* this);
s32 Player_ActionToModelGroup(Player* this, s32 actionParam);
void Player_SetModelsForHoldingShield(Player* this);
void Player_SetModels(Player* this, s32 modelGroup);
void Player_SetModelGroup(Player* this, s32 modelGroup);
void func_8008EC70(Player* this);
void Player_SetEquipmentData(PlayState* play, Player* this);
void Player_UpdateBottleHeld(PlayState* play, Player* this, s32 item, s32 actionParam);
void func_8008EDF0(Player* this);
void func_8008EE08(Player* this);
void func_8008EEAC(PlayState* play, Actor* actor);
s32 func_8008EF44(PlayState* play, s32 ammo);
s32 Player_IsBurningStickInRange(PlayState* play, Vec3f* pos, f32 radius, f32 arg3);
s32 Player_IsBurningStickInRange(PlayState* play, Vec3f* pos, f32 xzRange, f32 yRange);
s32 Player_GetStrength(void);
u8 Player_GetMask(PlayState* play);
Player* Player_UnsetMask(PlayState* play);
s32 Player_HasMirrorShieldEquipped(PlayState* play);
s32 Player_HasMirrorShieldSetToDraw(PlayState* play);
s32 Player_ActionToMagicSpell(Player* player, s32 actionParam);
s32 Player_HoldsHookshot(Player* player);
s32 func_8008F128(Player* player);
s32 Player_ActionToMagicSpell(Player* this, s32 actionParam);
s32 Player_HoldsHookshot(Player* this);
s32 func_8008F128(Player* this);
s32 Player_ActionToMeleeWeapon(s32 actionParam);
s32 Player_GetMeleeWeaponHeld(Player* player);
s32 Player_HoldsTwoHandedWeapon(Player* player);
s32 Player_HoldsBrokenKnife(Player* player);
s32 Player_ActionToBottle(Player* player, s32 actionParam);
s32 Player_GetBottleHeld(Player* player);
s32 Player_ActionToExplosive(Player* player, s32 actionParam);
s32 Player_GetExplosiveHeld(Player* player);
s32 func_8008F2BC(Player* player, s32 actionParam);
s32 Player_GetMeleeWeaponHeld(Player* this);
s32 Player_HoldsTwoHandedWeapon(Player* this);
s32 Player_HoldsBrokenKnife(Player* this);
s32 Player_ActionToBottle(Player* this, s32 actionParam);
s32 Player_GetBottleHeld(Player* this);
s32 Player_ActionToExplosive(Player* this, s32 actionParam);
s32 Player_GetExplosiveHeld(Player* this);
s32 func_8008F2BC(Player* this, s32 actionParam);
s32 func_8008F2F8(PlayState* play);
void Player_DrawImpl(PlayState* play, void** skeleton, Vec3s* jointTable, s32 dListCount, s32 lod, s32 tunic,
s32 boots, s32 face, OverrideLimbDrawOpa overrideLimbDraw, PostLimbDrawOpa postLimbDraw,
void* data);
s32 Player_OverrideLimbDrawGameplayCommon(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
void* data);
void* thisx);
s32 Player_OverrideLimbDrawGameplayDefault(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
void* data);
s32 Player_OverrideLimbDrawGameplayFirstPerson(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos,
Vec3s* rot, void* data);
s32 Player_OverrideLimbDrawGameplay_80090440(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos,
Vec3s* rot, void* data);
u8 func_80090480(PlayState* play, ColliderQuad* collider, WeaponInfo* weaponDim, Vec3f* newTip,
Vec3f* newBase);
void Player_DrawGetItem(PlayState* play, Player* player);
void Player_PostLimbDrawGameplay(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void* data);
void* thisx);
s32 Player_OverrideLimbDrawGameplayFirstPerson(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
void* thisx);
s32 Player_OverrideLimbDrawGameplay_80090440(PlayState* play, s32 limbIndex, Gfx** dList, Vec3f* pos, Vec3s* rot,
void* thisx);
u8 func_80090480(PlayState* play, ColliderQuad* collider, WeaponInfo* weaponInfo, Vec3f* newTip, Vec3f* newBase);
void Player_DrawGetItem(PlayState* play, Player* this);
void Player_PostLimbDrawGameplay(PlayState* play, s32 limbIndex, Gfx** dList, Vec3s* rot, void* thisx);
u32 func_80091738(PlayState* play, u8* segment, SkelAnime* skelAnime);
void Player_DrawPause(PlayState* play, u8* segment, SkelAnime* skelAnime, Vec3f* pos, Vec3s* rot, f32 scale,
s32 sword, s32 tunic, s32 shield, s32 boots);
@ -1284,10 +1281,10 @@ void func_800A6394(Actor* actor, PlayState* play, Skin* skin, SkinPostDraw postD
SkinOverrideLimbDraw overrideLimbDraw, s32 setTranslation, s32 arg6);
void func_800A63CC(Actor* actor, PlayState* play, Skin* skin, SkinPostDraw postDraw,
SkinOverrideLimbDraw overrideLimbDraw, s32 setTranslation, s32 arg6, s32 drawFlags);
void Skin_GetLimbPos(Skin* skin, s32 limbIndex, Vec3f* arg2, Vec3f* dst);
void Skin_GetLimbPos(Skin* skin, s32 limbIndex, Vec3f* offset, Vec3f* dst);
void Skin_Init(PlayState* play, Skin* skin, SkeletonHeader* skeletonHeader, AnimationHeader* animationHeader);
void Skin_Free(PlayState* play, Skin* skin);
s32 Skin_ApplyAnimTransformations(Skin* skin, MtxF* mf, Actor* actor, s32 setTranslation);
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);
@ -1420,7 +1417,7 @@ void TransitionFade_SetColor(void* this, u32 color);
void TransitionFade_SetType(void* this, s32 type);
void ShrinkWindow_SetVal(s32 value);
u32 ShrinkWindow_GetVal(void);
void ShrinkWindow_SetCurrentVal(s32 nowVal);
void ShrinkWindow_SetCurrentVal(s32 currentVal);
u32 ShrinkWindow_GetCurrentVal(void);
void ShrinkWindow_Init(void);
void ShrinkWindow_Destroy(void);
@ -1478,39 +1475,39 @@ void KaleidoScopeCall_Init(PlayState* play);
void KaleidoScopeCall_Destroy(PlayState* play);
void KaleidoScopeCall_Update(PlayState* play);
void KaleidoScopeCall_Draw(PlayState* play);
void func_800BC490(PlayState* play, s16 point);
s32 func_800BC56C(PlayState* play, s16 arg1);
void func_800BC590(PlayState* play);
Gfx* Play_SetFog(PlayState* play, Gfx* gfx);
void func_800BC490(PlayState* this, s16 point);
s32 func_800BC56C(PlayState* this, s16 arg1);
void func_800BC590(PlayState* this);
Gfx* Play_SetFog(PlayState* this, Gfx* gfx);
void Play_Destroy(GameState* thisx);
void Play_Init(GameState* thisx);
void Play_Main(GameState* thisx);
s32 Play_InCsMode(PlayState* play);
f32 func_800BFCB8(PlayState* play, MtxF* mf, Vec3f* vec);
void* Play_LoadFile(PlayState* play, RomFile* file);
void Play_GetScreenPos(PlayState* play, Vec3f* src, Vec3f* dest);
s16 Play_CreateSubCamera(PlayState* play);
s16 Play_GetActiveCamId(PlayState* play);
s16 Play_ChangeCameraStatus(PlayState* play, s16 camId, s16 status);
void Play_ClearCamera(PlayState* play, s16 camId);
void Play_ClearAllSubCameras(PlayState* play);
Camera* Play_GetCamera(PlayState* play, s16 camId);
s32 Play_CameraSetAtEye(PlayState* play, s16 camId, Vec3f* at, Vec3f* eye);
s32 Play_CameraSetAtEyeUp(PlayState* play, s16 camId, Vec3f* at, Vec3f* eye, Vec3f* up);
s32 Play_CameraSetFov(PlayState* play, s16 camId, f32 fov);
s32 Play_SetCameraRoll(PlayState* play, s16 camId, s16 roll);
void Play_CopyCamera(PlayState* play, s16 destCamId, s16 srcCamId);
s32 func_800C0808(PlayState* play, s16 camId, Player* player, s16 setting);
s32 Play_CameraChangeSetting(PlayState* play, s16 camId, s16 setting);
void func_800C08AC(PlayState* play, s16 camId, s16 arg2);
void Play_SaveSceneFlags(PlayState* play);
void Play_SetupRespawnPoint(PlayState* play, s32 respawnMode, s32 playerParams);
void Play_TriggerVoidOut(PlayState* play);
void Play_TriggerRespawn(PlayState* play);
s32 func_800C0CB8(PlayState* play);
s32 FrameAdvance_IsEnabled(PlayState* play);
s32 func_800C0D34(PlayState* play, Actor* actor, s16* yaw);
s32 func_800C0DB4(PlayState* play, Vec3f* pos);
s32 Play_InCsMode(PlayState* this);
f32 func_800BFCB8(PlayState* this, MtxF* mf, Vec3f* vec);
void* Play_LoadFile(PlayState* this, RomFile* file);
void Play_GetScreenPos(PlayState* this, Vec3f* src, Vec3f* dest);
s16 Play_CreateSubCamera(PlayState* this);
s16 Play_GetActiveCamId(PlayState* this);
s16 Play_ChangeCameraStatus(PlayState* this, s16 camId, s16 status);
void Play_ClearCamera(PlayState* this, s16 camId);
void Play_ClearAllSubCameras(PlayState* this);
Camera* Play_GetCamera(PlayState* this, s16 camId);
s32 Play_CameraSetAtEye(PlayState* this, s16 camId, Vec3f* at, Vec3f* eye);
s32 Play_CameraSetAtEyeUp(PlayState* this, s16 camId, Vec3f* at, Vec3f* eye, Vec3f* up);
s32 Play_CameraSetFov(PlayState* this, s16 camId, f32 fov);
s32 Play_SetCameraRoll(PlayState* this, s16 camId, s16 roll);
void Play_CopyCamera(PlayState* this, s16 destCamId, s16 srcCamId);
s32 func_800C0808(PlayState* this, s16 camId, Player* player, s16 setting);
s32 Play_CameraChangeSetting(PlayState* this, s16 camId, s16 setting);
void func_800C08AC(PlayState* this, s16 camId, s16 arg2);
void Play_SaveSceneFlags(PlayState* this);
void Play_SetupRespawnPoint(PlayState* this, s32 respawnMode, s32 playerParams);
void Play_TriggerVoidOut(PlayState* this);
void Play_TriggerRespawn(PlayState* this);
s32 func_800C0CB8(PlayState* this);
s32 FrameAdvance_IsEnabled(PlayState* this);
s32 func_800C0D34(PlayState* this, Actor* actor, s16* yaw);
s32 func_800C0DB4(PlayState* this, Vec3f* pos);
void PreRender_SetValuesSave(PreRender* this, u32 width, u32 height, void* fbuf, void* zbuf, void* cvg);
void PreRender_Init(PreRender* this);
void PreRender_SetValues(PreRender* this, u32 width, u32 height, void* fbuf, void* zbuf);
@ -1616,7 +1613,7 @@ void ListAlloc_FreeAll(ListAlloc* this);
void Main_LogSystemHeap(void);
void Main(void* arg);
OSMesgQueue* PadMgr_LockSerialMesgQueue(PadMgr* padmgr);
void PadMgr_UnlockSerialMesgQueue(PadMgr* padmgr, OSMesgQueue* ctrlrqueue);
void PadMgr_UnlockSerialMesgQueue(PadMgr* padmgr, OSMesgQueue* serialEventQueue);
void PadMgr_LockPadData(PadMgr* padmgr);
void PadMgr_UnlockPadData(PadMgr* padmgr);
void PadMgr_RumbleControl(PadMgr* padmgr);
@ -1634,7 +1631,7 @@ void SpeedMeter_InitImpl(SpeedMeter* this, u32 arg1, u32 y);
void SpeedMeter_Init(SpeedMeter* this);
void SpeedMeter_Destroy(SpeedMeter* this);
void SpeedMeter_DrawTimeEntries(SpeedMeter* this, GraphicsContext* gfxCtx);
void SpeedMeter_InitAllocEntry(SpeedMeterAllocEntry* entry, u32 maxval, u32 val, u16 backColor, u16 foreColor, u32 ulx,
void SpeedMeter_InitAllocEntry(SpeedMeterAllocEntry* this, u32 maxval, u32 val, u16 backColor, u16 foreColor, u32 ulx,
u32 lrx, u32 uly, u32 lry);
void SpeedMeter_DrawAllocEntry(SpeedMeterAllocEntry* this, GraphicsContext* gfxCtx);
void SpeedMeter_DrawAllocEntries(SpeedMeter* meter, GraphicsContext* gfxCtx, GameState* state);
@ -1779,20 +1776,20 @@ void UCodeDisas_SetCurUCode(UCodeDisas*, void*);
Acmd* AudioSynth_Update(Acmd* cmdStart, s32* cmdCnt, s16* aiStart, s32 aiBufLen);
void AudioHeap_DiscardFont(s32 fontId);
void AudioHeap_DiscardSequence(s32 seqId);
void AudioHeap_WritebackDCache(void* mem, u32 size);
void AudioHeap_WritebackDCache(void* ramAddr, u32 size);
void* AudioHeap_AllocZeroedAttemptExternal(AudioAllocPool* pool, u32 size);
void* AudioHeap_AllocAttemptExternal(AudioAllocPool* pool, u32 size);
void* AudioHeap_AllocDmaMemory(AudioAllocPool* pool, u32 size);
void* AudioHeap_AllocDmaMemoryZeroed(AudioAllocPool* pool, u32 size);
void* AudioHeap_AllocZeroed(AudioAllocPool* pool, u32 size);
void* AudioHeap_Alloc(AudioAllocPool* pool, u32 size);
void AudioHeap_AllocPoolInit(AudioAllocPool* pool, void* mem, u32 size);
void AudioHeap_AllocPoolInit(AudioAllocPool* pool, void* ramAddr, u32 size);
void AudioHeap_PersistentCacheClear(AudioPersistentCache* persistent);
void AudioHeap_TemporaryCacheClear(AudioTemporaryCache* temporary);
void AudioHeap_PopCache(s32 tableType);
void AudioHeap_InitMainPools(s32 initPoolSize);
void* AudioHeap_AllocCached(s32 tableType, s32 size, s32 cache, s32 id);
void* AudioHeap_SearchCaches(s32 tableType, s32 arg1, s32 id);
void* AudioHeap_SearchCaches(s32 tableType, s32 cache, s32 id);
void* AudioHeap_SearchRegularCaches(s32 tableType, s32 cache, s32 id);
void AudioHeap_LoadFilter(s16* filter, s32 lowPassCutoff, s32 highPassCutoff);
s32 AudioHeap_ResetStep(void);
@ -1803,7 +1800,7 @@ void* AudioHeap_AllocSampleCache(u32 size, s32 fontId, void* sampleAddr, s8 medi
void AudioHeap_ApplySampleBankCache(s32 sampleBankId);
void AudioLoad_DecreaseSampleDmaTtls(void);
void* AudioLoad_DmaSampleData(u32 devAddr, u32 size, s32 arg2, u8* dmaIndexRef, s32 medium);
void AudioLoad_InitSampleDmaBuffers(s32 arg0);
void AudioLoad_InitSampleDmaBuffers(s32 numNotes);
s32 AudioLoad_IsFontLoadComplete(s32 fontId);
s32 AudioLoad_IsSeqLoadComplete(s32 seqId);
void AudioLoad_SetFontLoadStatus(s32 fontId, s32 loadStatus);
@ -1813,7 +1810,7 @@ s32 AudioLoad_SyncLoadInstrument(s32 fontId, s32 instId, s32 drumId);
void AudioLoad_AsyncLoadSeq(s32 seqId, s32 arg1, s32 retData, OSMesgQueue* retQueue);
void AudioLoad_AsyncLoadSampleBank(s32 sampleBankId, s32 arg1, s32 retData, OSMesgQueue* retQueue);
void AudioLoad_AsyncLoadFont(s32 fontId, s32 arg1, s32 retData, OSMesgQueue* retQueue);
u8* AudioLoad_GetFontsForSequence(s32 seqId, u32* arg1);
u8* AudioLoad_GetFontsForSequence(s32 seqId, u32* outNumFonts);
void AudioLoad_DiscardSeqFonts(s32 seqId);
s32 AudioLoad_SyncInitSeqPlayer(s32 playerIdx, s32 seqId, s32 arg2);
s32 AudioLoad_SyncInitSeqPlayerSkipTicks(s32 playerIdx, s32 seqId, s32 skipTicks);
@ -1829,21 +1826,21 @@ void AudioLoad_ScriptLoad(s32 tableType, s32 id, s8* status);
void AudioLoad_ProcessScriptLoads(void);
void AudioLoad_InitScriptLoads(void);
AudioTask* func_800E4FE0(void);
void Audio_QueueCmdF32(u32 arg0, f32 arg1);
void Audio_QueueCmdS32(u32 arg0, s32 arg1);
void Audio_QueueCmdS8(u32 arg0, s8 arg1);
void Audio_QueueCmdU16(u32 arg0, u16 arg1);
void Audio_QueueCmdF32(u32 opArgs, f32 data);
void Audio_QueueCmdS32(u32 opArgs, s32 data);
void Audio_QueueCmdS8(u32 opArgs, s8 data);
void Audio_QueueCmdU16(u32 opArgs, u16 data);
s32 Audio_ScheduleProcessCmds(void);
u32 func_800E5E20(u32* arg0);
u32 func_800E5E20(u32* out);
u8* func_800E5E84(s32 arg0, u32* arg1);
s32 func_800E5EDC(void);
s32 func_800E5F88(s32 arg0);
s32 func_800E5F88(s32 resetPreloadID);
void Audio_PreNMIInternal(void);
s32 func_800E6680(void);
u32 Audio_NextRandom(void);
void Audio_InitMesgQueues(void);
void Audio_InvalDCache(void* buf, s32 size);
void Audio_WritebackDCache(void* mem, s32 size);
void Audio_WritebackDCache(void* buf, s32 size);
s32 osAiSetNextBuffer(void*, u32);
void Audio_InitNoteSub(Note* note, NoteSubEu* sub, NoteSubAttributes* attrs);
void Audio_NoteSetResamplingRate(NoteSubEu* noteSubEu, f32 resamplingRateInput);
@ -1876,7 +1873,7 @@ Note* Audio_AllocNoteFromDecaying(NotePool* pool, SequenceLayer* layer);
Note* Audio_AllocNoteFromActive(NotePool* pool, SequenceLayer* layer);
Note* Audio_AllocNote(SequenceLayer* layer);
void Audio_NoteInitAll(void);
void Audio_SequenceChannelProcessSound(SequenceChannel* channel, s32 recalculateVolume, s32 b);
void Audio_SequenceChannelProcessSound(SequenceChannel* channel, s32 recalculateVolume, s32 applyBend);
void Audio_SequencePlayerProcessSound(SequencePlayer* seqPlayer);
f32 Audio_GetPortamentoFreqScale(Portamento* p);
s16 Audio_GetVibratoPitchChange(VibratoState* vib);
@ -1919,7 +1916,7 @@ void func_800F436C(Vec3f* pos, u16 sfxId, f32 arg2);
void func_800F4414(Vec3f* pos, u16 sfxId, f32);
void func_800F44EC(s8 arg0, s8 arg1);
void func_800F4524(Vec3f* pos, u16 sfxId, s8 arg2);
void func_800F4254(Vec3f* pos, u8 arg1);
void func_800F4254(Vec3f* pos, u8 level);
void Audio_PlaySoundRiver(Vec3f* pos, f32 freqScale);
void Audio_PlaySoundWaterfall(Vec3f* pos, f32 freqScale);
void func_800F47BC(void);
@ -1957,7 +1954,7 @@ void func_800F64E0(u8 arg0);
void func_800F6584(u8 arg0);
void Audio_SetEnvReverb(s8 reverb);
void Audio_SetCodeReverb(s8 reverb);
void func_800F6700(s8 outputMode);
void func_800F6700(s8 arg0);
void Audio_SetBaseFilter(u8);
void Audio_SetExtraFilter(u8);
void Audio_SetCutsceneFlag(s8 flag);
@ -1986,7 +1983,7 @@ void func_800F8884(u8 bankId, Vec3f* pos);
void Audio_StopSfxByPosAndBank(u8 bankId, Vec3f* pos);
void Audio_StopSfxByPos(Vec3f* pos);
void func_800F9280(u8 playerIdx, u8 seqId, u8 arg2, u16 fadeTimer);
void Audio_QueueSeqCmd(u32 bgmID);
void Audio_QueueSeqCmd(u32 cmd);
void Audio_StopSfxByPosAndId(Vec3f* pos, u16 sfxId);
void Audio_StopSfxByTokenAndId(u8 token, u16 sfxId);
void Audio_StopSfxById(u32 sfxId);
@ -1998,7 +1995,7 @@ void func_800F9474(u8, u16);
void func_800F94FC(u32);
void Audio_ProcessSeqCmd(u32);
void Audio_ProcessSeqCmds(void);
u16 func_800FA0B4(u8 a0);
u16 func_800FA0B4(u8 playerIdx);
s32 func_800FA11C(u32 arg0, u32 arg1);
void func_800FA174(u8);
void func_800FA18C(u8, u8);
@ -2021,7 +2018,7 @@ void RcpUtils_Reset(void);
void* Overlay_AllocateAndLoad(uintptr_t vRomStart, uintptr_t vRomEnd, void* vRamStart, void* vRamEnd);
void MtxConv_F2L(Mtx* m1, MtxF* m2);
void MtxConv_L2F(MtxF* m1, Mtx* m2);
void Overlay_Relocate(void* allocatedVRamAddress, OverlayRelocationSection* overlayInfo, void* vRamAddress);
void Overlay_Relocate(void* allocatedVRamAddress, OverlayRelocationSection* overlayInfo, void* vRamStart);
s32 Overlay_Load(uintptr_t vRomStart, uintptr_t vRomEnd, void* vRamStart, void* vRamEnd, void* allocatedVRamAddress);
// ? func_800FC800(?);
// ? func_800FC83C(?);
@ -2146,16 +2143,16 @@ void guScale(Mtx* m, f32 x, f32 y, f32 z);
f32 sinf(f32);
s16 sins(u16);
OSTask* _VirtualToPhysicalTask(OSTask* intp);
void osSpTaskLoad(OSTask* task);
void osSpTaskStartGo(OSTask* task);
void osSpTaskLoad(OSTask* intp);
void osSpTaskStartGo(OSTask* tp);
void __osSiCreateAccessQueue(void);
void __osSiGetAccess(void);
void __osSiRelAccess(void);
s32 osContInit(OSMesgQueue* mq, u8* ctl_present_bitfield, OSContStatus* status);
void __osContGetInitData(u8* ctl_present_bitfield, OSContStatus* status);
s32 osContInit(OSMesgQueue* mq, u8* ctlBitfield, OSContStatus* status);
void __osContGetInitData(u8* ctlBitfield, OSContStatus* status);
void __osPackRequestData(u8 poll);
s32 osContStartReadData(OSMesgQueue* mq);
void osContGetReadData(OSContPad* pad);
void osContGetReadData(OSContPad* contData);
void __osPackReadData(void);
void guPerspectiveF(f32 mf[4][4], u16* perspNorm, f32 fovy, f32 aspect, f32 near, f32 far, f32 scale);
void guPerspective(Mtx* m, u16* perspNorm, f32 fovy, f32 aspect, f32 near, f32 far, f32 scale);
@ -2170,12 +2167,12 @@ void __osPfsGetOneChannelData(s32 channel, OSContStatus* contData);
void guMtxIdentF(f32 mf[4][4]);
void guLookAtF(f32 mf[4][4], f32 xEye, f32 yEye, f32 zEye, f32 xAt, f32 yAt, f32 zAt, f32 xUp, f32 yUp, f32 zUp);
void guLookAt(Mtx*, f32 xEye, f32 yEye, f32 zEye, f32 xAt, f32 yAt, f32 zAt, f32 xUp, f32 yUp, f32 zUp);
s32 osPfsAllocateFile(OSPfs* pfs, u16 companyCode, u32 gameCode, u8* gameName, u8* extName, s32 length, s32* fileNo);
s32 osPfsAllocateFile(OSPfs* pfs, u16 companyCode, u32 gameCode, u8* gameName, u8* extName, s32 fileSize, s32* fileNo);
s32 __osPfsDeclearPage(OSPfs* pfs, __OSInode* inode, s32 fileSizeInPages, s32* startPage, u8 bank, s32* decleared,
s32* finalPage);
s32 osStopTimer(OSTimer* timer);
u16 __osSumcalc(u8* ptr, s32 length);
s32 __osIdCheckSum(u16* ptr, u16* csum, u16* icsum);
s32 __osIdCheckSum(u16* ptr, u16* checkSum, u16* idSum);
s32 __osRepairPackId(OSPfs* pfs, __OSPackId* badid, __OSPackId* newid);
s32 __osCheckPackId(OSPfs* pfs, __OSPackId* check);
s32 __osGetId(OSPfs* pfs);
@ -2218,7 +2215,7 @@ void guS2DInitBg(uObjBg* bg);
s32 __osPfsSelectBank(OSPfs* pfs, u8 bank);
s32 osContSetCh(u8 ch);
s32 osPfsFileState(OSPfs* pfs, s32 fileNo, OSPfsState* state);
s32 osPfsInitPak(OSMesgQueue* mq, OSPfs* pfs, s32 channel);
s32 osPfsInitPak(OSMesgQueue* queue, OSPfs* pfs, s32 channel);
s32 __osPfsCheckRamArea(OSPfs* pfs);
s32 osPfsChecker(OSPfs* pfs);
s32 func_80105788(OSPfs* pfs, __OSInodeCache* cache);

View file

@ -40,8 +40,8 @@ typedef struct {
OSIntMask osSetIntMask(OSIntMask);
void __osSetHWIntrRoutine(OSHWIntr interrupt, s32 (*callback)(void), void *sp);
void __osGetHWIntrRoutine(OSHWIntr interrupt, s32 (**callbackOut)(void), void **spOut);
void __osSetHWIntrRoutine(OSHWIntr intr, s32 (*callback)(void), void* sp);
void __osGetHWIntrRoutine(OSHWIntr intr, s32 (**callbackOut)(void), void** spOut);
void __osSetGlobalIntMask(OSHWIntr mask);
void __osResetGlobalIntMask(OSHWIntr mask);

View file

@ -47,17 +47,17 @@ typedef struct {
typedef s32 (*OverrideCurveLimbDraw)(struct PlayState* play, SkelCurve* skelCuve, s32 limbIndex, void* thisx);
typedef void (*PostCurveLimbDraw)(struct PlayState* play, SkelCurve* skelCuve, s32 limbIndex, void* thisx);
f32 Curve_Interpolate(f32 x, CurveInterpKnot* transData, s32 refIdx);
f32 Curve_Interpolate(f32 x, CurveInterpKnot* knots, s32 knotCount);
void SkelCurve_Clear(SkelCurve* skelCurve);
s32 SkelCurve_Init(struct PlayState* play, SkelCurve* skelCurve, CurveSkeletonHeader* limbListSeg, CurveAnimationHeader* transUpdIdx);
s32 SkelCurve_Init(struct PlayState* play, SkelCurve* skelCurve, CurveSkeletonHeader* skeletonHeaderSeg,
CurveAnimationHeader* animation);
void SkelCurve_Destroy(struct PlayState* play, SkelCurve* skelCurve);
void SkelCurve_SetAnim(SkelCurve* skelCurve, CurveAnimationHeader* transUpdIdx, f32 arg2, f32 endFrame, f32 curFrame, f32 playSpeed);
void SkelCurve_SetAnim(SkelCurve* skelCurve, CurveAnimationHeader* animation, f32 arg2, f32 endFrame, f32 curFrame,
f32 playSpeed);
s32 SkelCurve_Update(struct PlayState* play, SkelCurve* skelCurve);
void SkelCurve_Draw(Actor* actor, struct PlayState* play, SkelCurve* skelCurve, OverrideCurveLimbDraw overrideLimbDraw, PostCurveLimbDraw postLimbDraw, s32 lod, void* thisx);
void SkelCurve_Draw(Actor* actor, struct PlayState* play, SkelCurve* skelCurve, OverrideCurveLimbDraw overrideLimbDraw,
PostCurveLimbDraw postLimbDraw, s32 lod, void* data);
// ZAPD compatibility typedefs
// TODO: Remove when ZAPD adds support for them

View file

@ -1,7 +1,7 @@
#include "ultra64.h"
#include "global.h"
void AudioHeap_InitSampleCaches(u32 persistentSize, u32 temporarySize);
void AudioHeap_InitSampleCaches(u32 persistentSampleCacheSize, u32 temporarySampleCacheSize);
SampleCacheEntry* AudioHeap_AllocTemporarySampleCacheEntry(u32 size);
SampleCacheEntry* AudioHeap_AllocPersistentSampleCacheEntry(u32 size);
void AudioHeap_DiscardSampleCacheEntry(SampleCacheEntry* entry);

View file

@ -21,12 +21,12 @@ typedef enum {
CHAN_UPD_STEREO // 14
} ChannelUpdateType;
void func_800E6300(SequenceChannel* channel, AudioCmd* arg1);
void func_800E6300(SequenceChannel* channel, AudioCmd* cmd);
void func_800E59AC(s32 playerIdx, s32 fadeTimer);
void Audio_InitMesgQueues(void);
AudioTask* func_800E5000(void);
void Audio_ProcessCmds(u32);
void func_800E6128(SequencePlayer* seqPlayer, AudioCmd* arg1);
void func_800E6128(SequencePlayer* seqPlayer, AudioCmd* cmd);
void func_800E5958(s32 playerIdx, s32 fadeTimer);
s32 func_800E66C0(s32 arg0);

View file

@ -16,7 +16,7 @@ void BossDodongo_Walk(BossDodongo* this, PlayState* play);
void BossDodongo_Inhale(BossDodongo* this, PlayState* play);
void BossDodongo_BlowFire(BossDodongo* this, PlayState* play);
void BossDodongo_Roll(BossDodongo* this, PlayState* play);
void BossDodongo_SpawnFire(BossDodongo* this, PlayState* play, s16 arg2);
void BossDodongo_SpawnFire(BossDodongo* this, PlayState* play, s16 params);
void BossDodongo_Explode(BossDodongo* this, PlayState* play);
void BossDodongo_LayDown(BossDodongo* this, PlayState* play);
void BossDodongo_Vulnerable(BossDodongo* this, PlayState* play);

View file

@ -65,7 +65,7 @@ void BossTw_Destroy(Actor* thisx, PlayState* play);
void BossTw_Update(Actor* thisx, PlayState* play);
void BossTw_Draw(Actor* thisx, PlayState* play);
void BossTw_TwinrovaDamage(BossTw* this, PlayState* play, u8 arg2);
void BossTw_TwinrovaDamage(BossTw* this, PlayState* play, u8 damage);
void BossTw_TwinrovaSetupFly(BossTw* this, PlayState* play);
void BossTw_DrawEffects(PlayState* play);
void BossTw_TwinrovaLaugh(BossTw* this, PlayState* play);

View file

@ -929,7 +929,7 @@ void EnHorse_Freeze(EnHorse* this) {
}
}
void EnHorse_ChangeIdleAnimation(EnHorse* this, s32 arg1, f32 arg2);
void EnHorse_ChangeIdleAnimation(EnHorse* this, s32 anim, f32 morphFrames);
void EnHorse_StartMountedIdleResetAnim(EnHorse* this);
void EnHorse_StartMountedIdle(EnHorse* this);
void EnHorse_StartGalloping(EnHorse* this);
@ -1809,7 +1809,7 @@ void EnHorse_StartIdleRidable(EnHorse* this) {
this->stateFlags &= ~ENHORSE_UNRIDEABLE;
}
void EnHorse_StartMovingAnimation(EnHorse* this, s32 arg1, f32 arg2, f32 arg3);
void EnHorse_StartMovingAnimation(EnHorse* this, s32 animId, f32 morphFrames, f32 startFrame);
void EnHorse_Idle(EnHorse* this, PlayState* play) {
this->actor.speedXZ = 0.0f;

View file

@ -31,7 +31,7 @@ void func_80ACB3E0(EnOwl* this, PlayState* play);
void EnOwl_WaitLWPreSaria(EnOwl* this, PlayState* play);
void EnOwl_WaitLWPostSaria(EnOwl* this, PlayState* play);
void func_80ACD4D4(EnOwl* this, PlayState* play);
void func_80ACD130(EnOwl* this, PlayState* play, s32 arg2);
void func_80ACD130(EnOwl* this, PlayState* play, s32 idx);
void func_80ACBAB8(EnOwl* this, PlayState* play);
void func_80ACD2CC(EnOwl* this, PlayState* play);
void func_80ACAA54(EnOwl* this, PlayState* play);

View file

@ -16,7 +16,7 @@ void ObjectKankyo_Destroy(Actor* thisx, PlayState* play);
void ObjectKankyo_Update(Actor* thisx, PlayState* play);
void ObjectKankyo_Draw(Actor* thisx, PlayState* play);
void ObjectKankyo_SetupAction(ObjectKankyo* this, ObjectKankyoActionFunc func);
void ObjectKankyo_SetupAction(ObjectKankyo* this, ObjectKankyoActionFunc action);
void ObjectKankyo_Fairies(ObjectKankyo* this, PlayState* play);
void ObjectKankyo_SunGraveSparkInit(ObjectKankyo* this, PlayState* play);
void ObjectKankyo_Snow(ObjectKankyo* this, PlayState* play);