Files
ComplexPlane 74e69e9c7e Separately compilable headers (#13)
* Rename stcoli functions

* Add gen_compile_commands.py script

* Add shebang

* gen_compile_commands: pretend to be GCC

* Separately compilable game headers

* Separately compilable system dolphin headers

* Remove stcoli changes from this PR

* Fix EOF newlines
2022-02-21 18:23:59 -06:00

34 lines
837 B
C

#ifndef _DOLPHIN_PERF_H_
#define _DOLPHIN_PERF_H_
#include <dolphin/types.h>
typedef u8 PERFId;
typedef enum
{
PERF_CPU_EVENT,
PERF_CPU_GP_EVENT,
PERF_GP_EVENT,
} PerfType;
typedef void *(*PERFAllocator)(u32 size);
typedef void (*PERFDeallocator)(void *block);
typedef void (*PERFDrawCallback)(void);
u32 PERFInit(u32 numSamples, u32 numFramesHistory, u32 numTypes,
PERFAllocator allocator, PERFDeallocator deallocator, PERFDrawCallback initDraw);
void PERFEventStart(PERFId id);
void PERFEventEnd(PERFId id);
void PERFSetEvent(PERFId id, char *name, PerfType type);
void PERFSetDrawBWBarKey(BOOL tf);
void PERFDumpScreen(void);
void PERFStartFrame(void);
void PERFEndFrame(void);
void PERFStartAutoSampling(f32 msInterval);
void PERFStopAutoSampling(void);
void PERFPreDraw(void);
void PERFPostDraw(void);
#endif