mirror of
https://github.com/zeldaret/mm.git
synced 2026-06-20 23:51:12 -04:00
666cb6ad4a
* low hanging fruits on variables.h
* z_actor functions
* Move RomFile to z64object.h
* Revert "z_actor functions"
This reverts commit aa99967d16.
* yeet
* z64actor_dlftbls.h
* Move object segment declarations to object_table.c
* Move Camera functions
* z64nmi_buff.h
* fix merge
* su_mtx.h, sys_cmpdma.h and sys_initial_check.h
* sys_ucode.h
* sys_flashrom.h
* Remove unnecessary includes
* z64kanfont.h
* flg_set.h
* z64DLF.h
* z64lifemeter.h
* z64path.h
* format
* ObjectOverlay
* bss
* Yeet ObjectOverlay
* review
* review
* format
* bss
* z64font.h
44 lines
1.3 KiB
C
44 lines
1.3 KiB
C
#ifndef Z64FONT_H
|
|
#define Z64FONT_H
|
|
|
|
#include "PR/ultratypes.h"
|
|
#include "libc/stdint.h"
|
|
|
|
struct PlayState;
|
|
|
|
#define FONT_CHAR_TEX_WIDTH 16
|
|
#define FONT_CHAR_TEX_HEIGHT 16
|
|
//! TODO: Make this use `sizeof(AnyFontTextureSymbol)`
|
|
#define FONT_CHAR_TEX_SIZE ((16 * 16) / 2) // 16x16 I4 texture
|
|
|
|
// Font textures are loaded into here
|
|
typedef struct Font {
|
|
/* 0x00000 */ union {
|
|
u8 charBuf[2][FONT_CHAR_TEX_SIZE * 120];
|
|
u64 force_structure_alignment_charTex;
|
|
};
|
|
/* 0x07800 */ union {
|
|
u8 iconBuf[FONT_CHAR_TEX_SIZE];
|
|
u64 force_structure_alignment_icon;
|
|
};
|
|
/* 0x07880 */ union {
|
|
u8 fontBuf[FONT_CHAR_TEX_SIZE * 320];
|
|
u64 force_structure_alignment_font;
|
|
};
|
|
/* 0x11880 */ union {
|
|
char schar[1280]; // msgBuf
|
|
u16 wchar[640]; // msgBufWide
|
|
u64 force_structure_alignment_msg;
|
|
} msgBuf;
|
|
/* 0x11D80 */ uintptr_t messageStart;
|
|
/* 0x11D84 */ uintptr_t messageEnd;
|
|
/* 0x11D88 */ u8 unk_11D88; // current Char Buffer ?
|
|
} Font; // size = 0x11D90
|
|
|
|
void Font_LoadChar(struct PlayState* play, u16 codePointIndex, s32 offset);
|
|
void Font_LoadCharNES(struct PlayState* play, u8 codePointIndex, s32 offset);
|
|
void Font_LoadMessageBoxEndIcon(Font* font, u16 icon);
|
|
void Font_LoadOrderedFont(Font* font);
|
|
|
|
#endif
|