Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 0 additions & 1 deletion .clang-format
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
---
Language: Cpp
AccessModifierOffset: -4
AlignAfterOpenBracket: Align
AlignConsecutiveMacros: false
Expand Down
1 change: 1 addition & 0 deletions baseline.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions progress.json

Large diffs are not rendered by default.

26 changes: 26 additions & 0 deletions src/SB/Core/gc/.clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
---
BasedOnStyle: InheritParentConfig
IncludeBlocks: Regroup
SortIncludes: CaseSensitive
IncludeCategories:
# Hardware-specific core code
- Regex: '^"i'
Priority: 1
# Core code
- Regex: '^"(x|containers)'
Priority: 2
# Game code
- Regex: '^"z'
Priority: 3
# RenderWare
- Regex: "^<(rw|rt|rp|world)"
Priority: 4
# Dolphin SDK
- Regex: "^<dolphin"
Priority: 5
# Other includes
- Regex: "^<"
Priority: 6
- Regex: ".*"
Priority: 6
...
9 changes: 4 additions & 5 deletions src/SB/Core/gc/iAnim.cpp
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
#include "iAnim.h"

#include "iAnimSKB.h"
#include "xMath.h"

#include <rwcore.h>
#include <rtslerp.h>
#include <rwcore.h>

static U8 scratchBuffer[9120];

Expand Down Expand Up @@ -36,9 +35,9 @@ U32 iAnimBoneCount(void* RawData)
}

// non-matching: incorrect instruction order and regalloc
void iAnimBlend(F32 BlendFactor, F32 BlendRecip, U16* BlendTimeOffset,
F32* BoneTable, U32 BoneCount, xVec3* Tran1, xQuat* Quat1, xVec3* Tran2,
xQuat* Quat2, xVec3* TranDest, xQuat* QuatDest)
void iAnimBlend(F32 BlendFactor, F32 BlendRecip, U16* BlendTimeOffset, F32* BoneTable,
U32 BoneCount, xVec3* Tran1, xQuat* Quat1, xVec3* Tran2, xQuat* Quat2,
xVec3* TranDest, xQuat* QuatDest)
{
U32 i;
U32 invert = 0;
Expand Down
2 changes: 1 addition & 1 deletion src/SB/Core/gc/iAnimSKB.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#include "iAnimSKB.h"

#include <rwcore.h>
#include <rtslerp.h>
#include <rwcore.h>

#include <limits.h>

Expand Down
4 changes: 2 additions & 2 deletions src/SB/Core/gc/iCollide.cpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
#include "iCollide.h"

#include <types.h>

#include "xMathInlines.h"

#include <rpcollis.h>

#include <string.h>
#include <types.h>

static S32 sCollidingJSP = 0;
static F32 cbath = 0;
Expand Down
4 changes: 2 additions & 2 deletions src/SB/Core/gc/iCollide.h
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
#ifndef ICOLLIDE_H
#define ICOLLIDE_H

#include "xCollide.h"
#include "xEnv.h"
#include "xMath3.h"
#include "xModel.h"
#include "xEnv.h"
#include "xCollide.h"

void iBoxForModelLocal(xBox* o, const xModelInstance* m);
void iBoxForModel(xBox* o, const xModelInstance* m);
Expand Down
2 changes: 1 addition & 1 deletion src/SB/Core/gc/iCollideFast.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@
void iCollideFastInit(xScene* sc)
{
return;
}
}
3 changes: 2 additions & 1 deletion src/SB/Core/gc/iColor.h
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
#ifndef ICOLOR_H
#define ICOLOR_H

#include "xHud.h"

#include <types.h>
#include <xHud.h>

struct iColor_tag
{
Expand Down
7 changes: 4 additions & 3 deletions src/SB/Core/gc/iCutscene.cpp
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
#include "iCutscene.h"

#include "iModel.h"

#include "xMath.h"
#include "xpkrsvc.h"
#include "xstransvc.h"
#include "xMath.h"

#include "iModel.h"

#include <rwcore.h>

#include <string.h>

U32 read_sizzze = 0;
Expand Down
1 change: 1 addition & 0 deletions src/SB/Core/gc/iDraw.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
#include "iDraw.h"

#include <dolphin.h>

#include <stddef.h>

void iDrawSetFBMSK(U32 abgr)
Expand Down
2 changes: 1 addition & 1 deletion src/SB/Core/gc/iEnv.cpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#include "iEnv.h"

#include "iCamera.h"
#include "iModel.h"

#include "iCamera.h"
#include "xMemMgr.h"

static S32 sBeginDrawFX;
Expand Down
2 changes: 1 addition & 1 deletion src/SB/Core/gc/iEnv.h
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

#include "xJSP.h"

#include <rwcore.h>
#include <rpworld.h>
#include <rwcore.h>

struct iEnv
{
Expand Down
3 changes: 2 additions & 1 deletion src/SB/Core/gc/iFMV.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,11 @@

#include "xFile.h"
#include "xPar.h"
#include <dolphin/gx.h>

#include "zGlobals.h"

#include <dolphin/gx.h>

// #include <dolphin.h>

// FIXME: These should be in a RW header somewhere
Expand Down
4 changes: 2 additions & 2 deletions src/SB/Core/gc/iFMV.h
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
#ifndef IFMV_H
#define IFMV_H

#include <types.h>
#include <bink.h>
#include <rad3d.h>
#include <PowerPC_EABI_Support\MSL_C\MSL_Common\size_t.h>
#include <stddef.h>
#include <types.h>

#ifdef __cplusplus

Expand Down
3 changes: 2 additions & 1 deletion src/SB/Core/gc/iFX.h
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
#ifndef IFX_H
#define IFX_H

#include "types.h"
#include <rwcore.h>

#include <types.h>

RxPipeline* iFXanimUVCreatePipe();

#endif
5 changes: 3 additions & 2 deletions src/SB/Core/gc/iFile.h
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
#ifndef IFILE_H
#define IFILE_H

#include <types.h>
#include <dolphin.h>

#include <types.h>

enum IFILE_READSECTOR_STATUS
{
IFILE_RDSTAT_NOOP,
Expand Down Expand Up @@ -57,7 +58,7 @@ U32 iFileOpen(const char* name, S32 flags, tag_xFile* file);
S32 iFileSeek(tag_xFile* file, S32 offset, S32 whence);
U32 iFileRead(tag_xFile* file, void* buf, U32 size);
S32 iFileReadAsync(tag_xFile* file, void* buf, U32 aSize, void (*callback)(tag_xFile*),
S32 priority);
S32 priority);
IFILE_READSECTOR_STATUS iFileReadAsyncStatus(S32 key, S32* amtToFar);
U32 iFileClose(tag_xFile* file);
U32 iFileGetSize(tag_xFile* file);
Expand Down
2 changes: 1 addition & 1 deletion src/SB/Core/gc/iLight.h
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
#include "xFColor.h"
#include "xMath3.h"

#include <rwcore.h>
#include <rpworld.h>
#include <rwcore.h>

#define ILIGHT_TYPE_NONE 0
#define ILIGHT_TYPE_POINT 1
Expand Down
2 changes: 1 addition & 1 deletion src/SB/Core/gc/iMath.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#include "iMath.h"

#include <PowerPC_EABI_Support\MSL_C\MSL_Common\cmath>
#include <PowerPC_EABI_Support/MSL_C/MSL_Common/cmath>

F32 isin(F32 x)
{
Expand Down
2 changes: 1 addition & 1 deletion src/SB/Core/gc/iMath.h
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#ifndef IMATH_H
#define IMATH_H

#include <types.h>
#include <intrin.h>
#include <types.h>

#ifdef __MWERKS__
#define iabs(x) (float)(__fabs((float)x))
Expand Down
2 changes: 0 additions & 2 deletions src/SB/Core/gc/iMath3.h
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
#ifndef IMATH3_H
#define IMATH3_H

#include "xMath3.h"
#include "xIsect.h"
#include "xRay3.h"

#include <rwcore.h>
Expand Down
7 changes: 5 additions & 2 deletions src/SB/Core/gc/iMemMgr.cpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,14 @@
#include "iMemMgr.h"

#include "iSystem.h"

#include "xMemMgr.h"

#include <types.h>
#include <PowerPC_EABI_Support/MSL_C/MSL_Common/stdlib.h>
#include <dolphin.h>

#include <PowerPC_EABI_Support/MSL_C/MSL_Common/stdlib.h>
#include <types.h>

U32 mem_top_alloc;
U32 mem_base_alloc;
volatile OSHeapHandle the_heap;
Expand Down
3 changes: 2 additions & 1 deletion src/SB/Core/gc/iMemMgr.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
#ifndef IMEMMGR_H
#define IMEMMGR_H

#include "dolphin/os/OSAlloc.h"
#include <dolphin/os/OSAlloc.h>

#include <types.h>

extern U32 mem_base_alloc;
Expand Down
Loading
Loading