mirror of
https://github.com/zeldaret/mm.git
synced 2024-11-27 06:40:36 +00:00
26207594f2
* Bring over format.sh and .clang-tidy and run it * Little fixes * Adjustments * Jenkins kick * Jenkins kick 2 * format * small fixes * Bring over new formatter by Roman Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com> * Force use of clang-11 * check_format * Update error messages * Fix from Tharo for python3.6 Co-authored-by: Tharo <17233964+Thar0@users.noreply.github.com> * Just use nproc to determine num jobs for check format * Update error message * AnimatedMat_DrawStepOpa texture arg -> matAnim * Fix enTwig draw prototype * Tidying up * Bring over fixes in OoT #1387 Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com> * Fix * Update doc tools * PR Co-authored-by: Roman971 <32455037+Roman971@users.noreply.github.com> Co-authored-by: Tharo <17233964+Thar0@users.noreply.github.com>
50 lines
1.6 KiB
C
50 lines
1.6 KiB
C
#ifndef GFXPRINT_H
|
|
#define GFXPRINT_H
|
|
|
|
#include "color.h"
|
|
#include "PR/gbi.h"
|
|
#include "PR/ultratypes.h"
|
|
#include "xstdio.h"
|
|
|
|
#define GFXP_UNUSED "\x8E"
|
|
#define GFXP_UNUSED_CHAR 0x8E
|
|
#define GFXP_HIRAGANA "\x8D"
|
|
#define GFXP_HIRAGANA_CHAR 0x8D
|
|
#define GFXP_KATAKANA "\x8C"
|
|
#define GFXP_KATAKANA_CHAR 0x8C
|
|
#define GFXP_RAINBOW_ON "\x8B"
|
|
#define GFXP_RAINBOW_ON_CHAR 0x8B
|
|
#define GFXP_RAINBOW_OFF "\x8A"
|
|
#define GFXP_RAINBOW_OFF_CHAR 0x8A
|
|
|
|
typedef struct GfxPrint {
|
|
/* 0x00 */ PrintCallback callback;
|
|
/* 0x04 */ Gfx* dList;
|
|
/* 0x08 */ u16 posX;
|
|
/* 0x0A */ u16 posY;
|
|
/* 0x0C */ u16 baseX;
|
|
/* 0x0E */ u8 baseY;
|
|
/* 0x0F */ u8 flags;
|
|
/* 0x10 */ Color_RGBA8_u32 color;
|
|
/* 0x14 */ UNK_TYPE1 unk_14[0x1C]; // unused
|
|
} GfxPrint; // size = 0x30
|
|
|
|
void GfxPrint_Setup(GfxPrint* this);
|
|
void GfxPrint_SetColor(GfxPrint* this, u32 r, u32 g, u32 b, u32 a);
|
|
void GfxPrint_SetPosPx(GfxPrint* this, s32 x, s32 y);
|
|
void GfxPrint_SetPos(GfxPrint* this, s32 x, s32 y);
|
|
void GfxPrint_SetBasePosPx(GfxPrint* this, s32 x, s32 y);
|
|
void GfxPrint_PrintCharImpl(GfxPrint* this, u8 c);
|
|
void GfxPrint_PrintChar(GfxPrint* this, u8 c);
|
|
void GfxPrint_PrintStringWithSize(GfxPrint* this, const void* buffer, size_t charSize, size_t charCount);
|
|
void GfxPrint_PrintString(GfxPrint* this, const char* str);
|
|
void* GfxPrint_Callback(void* arg, const char* str, size_t size);
|
|
void GfxPrint_Init(GfxPrint* this);
|
|
void GfxPrint_Destroy(GfxPrint* printer);
|
|
void GfxPrint_Open(GfxPrint* this, Gfx* dList);
|
|
Gfx* GfxPrint_Close(GfxPrint* this);
|
|
s32 GfxPrint_VPrintf(GfxPrint* this, const char* fmt, va_list args);
|
|
s32 GfxPrint_Printf(GfxPrint* this, const char* fmt, ...);
|
|
|
|
#endif
|