Imported most of dolphin/os
This commit is contained in:
parent
023cd90675
commit
970da00ce2
35 changed files with 6591 additions and 131 deletions
|
|
@ -9,17 +9,44 @@ extern "C" {
|
|||
|
||||
#define OS_FONT_ENCODE_ANSI 0u
|
||||
#define OS_FONT_ENCODE_SJIS 1u
|
||||
#define OS_FONT_ENCODE_UTF8 3u // UTF-8 [RFC 3629]
|
||||
#define OS_FONT_ENCODE_UTF16 4u // UTF-16BE [RFC 2781]
|
||||
#define OS_FONT_ENCODE_UTF32 5u // UTF-32
|
||||
#define OS_FONT_ENCODE_MAX 5u
|
||||
#define OS_FONT_ENCODE_VOID 0xffffu
|
||||
#define OS_FONT_SIZE_ANSI (288 + 131072) // 9 sheets
|
||||
#define OS_FONT_SIZE_SJIS (3840 + 1179648) // 1 sheet
|
||||
#define OS_FONT_ROM_SIZE_ANSI 0x03000
|
||||
#define OS_FONT_ROM_SIZE_SJIS 0x4D000
|
||||
|
||||
#define OS_FONT_PROPORTIONAL FALSE
|
||||
#define OS_FONT_FIXED TRUE
|
||||
typedef struct OSFontHeader
|
||||
{
|
||||
/*0x00*/ u16 fontType;
|
||||
u16 firstChar;
|
||||
u16 lastChar;
|
||||
u16 invalChar;
|
||||
/*0x08*/ u16 ascent;
|
||||
u16 descent;
|
||||
u16 width;
|
||||
u16 leading;
|
||||
/*0x10*/ u16 cellWidth;
|
||||
u16 cellHeight;
|
||||
/*0x14*/ u32 sheetSize;
|
||||
/*0x18*/ u16 sheetFormat;
|
||||
u16 sheetColumn;
|
||||
u16 sheetRow;
|
||||
u16 sheetWidth;
|
||||
/*0x20*/ u16 sheetHeight;
|
||||
u16 widthTable;
|
||||
u32 sheetImage;
|
||||
u32 sheetFullSize;
|
||||
u8 c0;
|
||||
u8 c1;
|
||||
u8 c2;
|
||||
u8 c3;
|
||||
} OSFontHeader;
|
||||
|
||||
u16 OSGetFontEncode(void);
|
||||
u16 OSSetFontEncode(u16 encode);
|
||||
BOOL OSInitFont(OSFontHeader *fontData);
|
||||
u32 OSLoadFont(OSFontHeader *fontData, void *temp);
|
||||
char *OSGetFontTexture(char *string, void **image, s32 *x, s32 *y, s32 *width);
|
||||
char *OSGetFontWidth(char *string, s32 *width);
|
||||
char *OSGetFontTexel(char *string, void *image, s32 pos, s32 stride, s32 *width);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue