mirror of
https://github.com/zeldaret/tp
synced 2026-08-18 05:38:47 -04:00
copy homebuttonLib from oot-vc (#2960)
* initial copy of hbm from sdk_2009-12-11 * some more nw4hbm cleanup * nw4hbm db mostly done * nw4hbm snd copied from oot-vc * nw4hbm ut copied * nw4hbm lyt copied * nw4hbm copied, mostly matching usa 1.0 * setup nw4hbm debug define * fix HBMDataInfo struct * add rvl sdk card lib
This commit is contained in:
@@ -0,0 +1,37 @@
|
||||
#ifndef _REVOLUTION_MEM_ALLOCATOR_H_
|
||||
#define _REVOLUTION_MEM_ALLOCATOR_H_
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#include <revolution/mem/heapCommon.h>
|
||||
#include <revolution/types.h>
|
||||
|
||||
typedef struct MEMAllocator MEMAllocator;
|
||||
typedef void* (*MEMFuncAllocatorAlloc)(MEMAllocator* pAllocator, u32 size);
|
||||
typedef void (*MEMFuncAllocatorFree)(MEMAllocator* pAllocator, void* memBlock);
|
||||
typedef struct MEMAllocatorFunc MEMAllocatorFunc;
|
||||
|
||||
struct MEMAllocatorFunc {
|
||||
MEMFuncAllocatorAlloc pfAlloc;
|
||||
MEMFuncAllocatorFree pfFree;
|
||||
};
|
||||
|
||||
struct MEMAllocator {
|
||||
const MEMAllocatorFunc* pFunc;
|
||||
void* pHeap;
|
||||
u32 heapParam1;
|
||||
u32 heapParam2;
|
||||
};
|
||||
|
||||
void* MEMAllocFromAllocator(MEMAllocator*, u32);
|
||||
void MEMFreeToAllocator(MEMAllocator*, void*);
|
||||
void MEMInitAllocatorForExpHeap(MEMAllocator*, MEMHeapHandle, int);
|
||||
void MEMInitAllocatorForFrmHeap(MEMAllocator* allocator, struct MEMiHeapHead* heap, s32 align);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif // _REVOLUTION_MEM_ALLOCATOR_H_
|
||||
Reference in New Issue
Block a user