mirror of
https://github.com/zeldaret/mm.git
synced 2026-09-08 19:32:23 -04:00
THA docs (#1177)
* THA docs Co-authored-by: Tharo <17233964+Thar0@users.noreply.github.com> * format * namefixer * yada * remove zero pad comment * Update include/z64.h Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com> * Update include/thga.h Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com> * namefixer * bss * namefixer --------- Co-authored-by: Tharo <17233964+Thar0@users.noreply.github.com> Co-authored-by: engineer124 <47598039+engineer124@users.noreply.github.com>
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
#ifndef THGA_H
|
||||
#define THGA_H
|
||||
|
||||
#include "tha.h"
|
||||
|
||||
typedef union TwoHeadGfxArena {
|
||||
struct { // Same as TwoHeadArena, with different types and field names for the head and tail pointers
|
||||
/* 0x0 */ size_t size;
|
||||
/* 0x4 */ void* start;
|
||||
/* 0x8 */ Gfx* p;
|
||||
/* 0xC */ void* d;
|
||||
};
|
||||
/* 0x0 */ TwoHeadArena tha;
|
||||
} TwoHeadGfxArena; // size = 0x10
|
||||
|
||||
void THGA_Init(TwoHeadGfxArena* thga, void* start, size_t size);
|
||||
void THGA_Destroy(TwoHeadGfxArena* thga);
|
||||
u32 THGA_IsCrash(TwoHeadGfxArena* thga);
|
||||
void THGA_Reset(TwoHeadGfxArena* thga);
|
||||
s32 THGA_GetRemaining(TwoHeadGfxArena* thga);
|
||||
Gfx* THGA_GetHead(TwoHeadGfxArena* thga);
|
||||
void THGA_SetHead(TwoHeadGfxArena* thga, Gfx* newHead);
|
||||
void* THGA_GetTail(TwoHeadGfxArena* thga);
|
||||
Gfx* THGA_AllocDisplayList(TwoHeadGfxArena* thga, size_t num);
|
||||
Gfx* THGA_AllocGfx(TwoHeadGfxArena* thga);
|
||||
Gfx* THGA_AllocGfx2(TwoHeadGfxArena* thga);
|
||||
void* THGA_AllocTail(TwoHeadGfxArena* thga, size_t size);
|
||||
Mtx* THGA_AllocMtxArray(TwoHeadGfxArena* thga, size_t num);
|
||||
Mtx* THGA_AllocMtx(TwoHeadGfxArena* thga);
|
||||
Vtx* THGA_AllocVtxArray(TwoHeadGfxArena* thga, size_t num);
|
||||
Vtx* THGA_AllocVtx(TwoHeadGfxArena* thga);
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user