mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-08 00:44:42 +00:00
[headers 14] libc64 headers (#2177)
* [headers 14] libc64 headers * bss * bss
This commit is contained in:
parent
cbf9eacf42
commit
76d97ac18a
16 changed files with 73 additions and 40 deletions
11
include/libc64/aprintf.h
Normal file
11
include/libc64/aprintf.h
Normal file
|
@ -0,0 +1,11 @@
|
|||
#ifndef LIBC64_APRINTF_H
|
||||
#define LIBC64_APRINTF_H
|
||||
|
||||
#include "ultra64.h"
|
||||
|
||||
#include "stdarg.h"
|
||||
|
||||
s32 PrintUtils_VPrintf(PrintCallback* pfn, const char* fmt, va_list args);
|
||||
s32 PrintUtils_Printf(PrintCallback* pfn, const char* fmt, ...);
|
||||
|
||||
#endif
|
28
include/libc64/malloc.h
Normal file
28
include/libc64/malloc.h
Normal file
|
@ -0,0 +1,28 @@
|
|||
#ifndef LIBC64_MALLOC_H
|
||||
#define LIBC64_MALLOC_H
|
||||
|
||||
#include "ultra64.h"
|
||||
#include "libc64/os_malloc.h"
|
||||
|
||||
void* SystemArena_Malloc(u32 size);
|
||||
void* SystemArena_MallocR(u32 size);
|
||||
void* SystemArena_Realloc(void* ptr, u32 newSize);
|
||||
void SystemArena_Free(void* ptr);
|
||||
void* SystemArena_Calloc(u32 num, u32 size);
|
||||
void SystemArena_GetSizes(u32* outMaxFree, u32* outFree, u32* outAlloc);
|
||||
void SystemArena_Check(void);
|
||||
void SystemArena_Init(void* start, u32 size);
|
||||
void SystemArena_Cleanup(void);
|
||||
s32 SystemArena_IsInitialized(void);
|
||||
|
||||
#if OOT_DEBUG
|
||||
void* SystemArena_MallocDebug(u32 size, const char* file, int line);
|
||||
void* SystemArena_MallocRDebug(u32 size, const char* file, int line);
|
||||
void* SystemArena_ReallocDebug(void* ptr, u32 newSize, const char* file, int line);
|
||||
void SystemArena_FreeDebug(void* ptr, const char* file, int line);
|
||||
void SystemArena_Display(void);
|
||||
#endif
|
||||
|
||||
extern Arena gSystemArena;
|
||||
|
||||
#endif
|
17
include/libc64/math64.h
Normal file
17
include/libc64/math64.h
Normal file
|
@ -0,0 +1,17 @@
|
|||
#ifndef LIBC64_MATH64_H
|
||||
#define LIBC64_MATH64_H
|
||||
|
||||
#include "ultra64.h"
|
||||
|
||||
f32 Math_FTanF(f32 angle);
|
||||
f32 Math_FFloorF(f32 x);
|
||||
f32 Math_FCeilF(f32 x);
|
||||
f32 Math_FRoundF(f32 x);
|
||||
f32 Math_FNearbyIntF(f32 x);
|
||||
f32 Math_FTruncF(f32 x);
|
||||
f32 Math_FAtanF(f32 x);
|
||||
f32 Math_FAtan2F(f32 y, f32 x);
|
||||
f32 Math_FAsinF(f32 x);
|
||||
f32 Math_FAcosF(f32 x);
|
||||
|
||||
#endif
|
12
include/libc64/sleep.h
Normal file
12
include/libc64/sleep.h
Normal file
|
@ -0,0 +1,12 @@
|
|||
#ifndef LIBC64_SLEEP_H
|
||||
#define LIBC64_SLEEP_H
|
||||
|
||||
#include "ultra64.h"
|
||||
|
||||
void Sleep_Cycles(OSTime cycles);
|
||||
void Sleep_Nsec(u32 nsec);
|
||||
void Sleep_Usec(u32 usec);
|
||||
void Sleep_Msec(u32 ms);
|
||||
void Sleep_Sec(u32 sec);
|
||||
|
||||
#endif
|
11
include/libc64/sprintf.h
Normal file
11
include/libc64/sprintf.h
Normal file
|
@ -0,0 +1,11 @@
|
|||
#ifndef LIBC64_SPRINTF_H
|
||||
#define LIBC64_SPRINTF_H
|
||||
|
||||
#include "ultra64.h"
|
||||
|
||||
#include "stdarg.h"
|
||||
|
||||
int vsprintf(char* dst, const char* fmt, va_list args);
|
||||
int sprintf(char* dst, const char* fmt, ...);
|
||||
|
||||
#endif
|
Loading…
Add table
Add a link
Reference in a new issue