Twilight Princess
Decompilation of The Legend of Zelda: Twilight Princess
Loading...
Searching...
No Matches
hbm.h
Go to the documentation of this file.
1#ifndef _REVOLUTION_HBM_H_
2#define _REVOLUTION_HBM_H_
3
4#include <revolution/kpad.h>
5#include <revolution/mem.h>
6
7#ifdef __cplusplus
8extern "C" {
9#endif
10
11#define NW4HBM_VERSION(major, minor) ((major & 0xFF) << 8 | minor & 0xFF)
12
24
26 HBM_SOUND_EVENT_0, // StartInitSound? and then num would not matter
27 HBM_SOUND_EVENT_1, // EndInitSound? and then num would not matter
28 HBM_SOUND_EVENT_2, // Fadeout, num = ms? see calc_fadeoutAnm
29 HBM_SOUND_EVENT_3, // Blackout, num = ms? from various
30 HBM_SOUND_EVENT_4, // ShutdownSound? and then num would not matter
31 HBM_SOUND_EVENT_PLAY, /* num = HBMSound_et (see below) */
32};
33
64
65typedef int HBMSoundCallback(int evt, int num);
66typedef struct HBMDataInfo {
67 /* 0x00 */ void* layoutBuf;
68 /* 0x04 */ void* spkSeBuf;
69 /* 0x08 */ void* msgBuf;
70 /* 0x0C */ void* configBuf;
71 /* 0x10 */ void* mem;
73 /* 0x18 */ int backFlag;
74 /* 0x1C */ int region;
75 /* 0x20 */ int cursor;
76 /* 0x28 */ u32 memSize;
77 /* 0x2C */ f32 frameDelta;
78 /* 0x30 */ Vec2 adjust;
80} HBMDataInfo; // size 0x3C
81
87
88typedef struct HBMControllerData {
89 HBMKPadData wiiCon[WPAD_MAX_CONTROLLERS];
90} HBMControllerData; // size 0x40
91
92void HBMCreate(const HBMDataInfo* pHBInfo);
93void HBMDelete(void);
94void HBMInit(void);
95HBMSelectBtnNum HBMCalc(const HBMControllerData* pController);
96void HBMDraw(void);
99void HBMStartBlackOut(void);
101
102void HBMCreateSound(void* soundData, void* memBuf, u32 memSize);
103void HBMDeleteSound(void);
104void HBMUpdateSound(void);
105
106#ifdef __cplusplus
107}
108#endif
109
110#endif // _REVOLUTION_HBM_H_
static BOOL flag
Definition DEMOAVX.c:20
void HBMUpdateSound(void)
Definition HBMBase.cpp:111
void HBMDelete(void)
Definition HBMBase.cpp:55
void HBMStartBlackOut(void)
Definition HBMBase.cpp:81
void HBMInit(void)
Definition HBMBase.cpp:60
struct HBMControllerData HBMControllerData
void HBMSetAdjustFlag(BOOL flag)
HBMSound_et
Definition hbm.h:34
@ HBM_SOUND_START_CONNECT_WINDOW
Definition hbm.h:51
@ HBM_SOUND_SELECT
Definition hbm.h:40
@ HBM_SOUND_CONNECTED1
Definition hbm.h:52
@ HBM_SOUND_VOLUME_MINUS_LIMIT
Definition hbm.h:47
@ HBM_SOUND_VOLUME_PLUS_LIMIT
Definition hbm.h:46
@ HBM_SOUND_RESET_APP
Definition hbm.h:38
@ HBM_SOUND_MANUAL_RETURN_APP
Definition hbm.h:62
@ HBM_SOUND_CONNECTED4
Definition hbm.h:55
@ HBM_SOUND_OPEN_CONTROLLER
Definition hbm.h:42
@ HBM_SOUND_MANUAL_SELECT
Definition hbm.h:59
@ HBM_SOUND_VOLUME_MINUS
Definition hbm.h:45
@ HBM_SOUND_MANUAL_CANCEL
Definition hbm.h:61
@ HBM_SOUND_VIBE_OFF
Definition hbm.h:50
@ HBM_SOUND_HOME_BUTTON
Definition hbm.h:35
@ HBM_SOUND_CONNECTED2
Definition hbm.h:53
@ HBM_SOUND_NOTHING_DONE
Definition hbm.h:48
@ HBM_SOUND_CLOSE_CONTROLLER
Definition hbm.h:43
@ HBM_SOUND_MANUAL_FOCUS
Definition hbm.h:58
@ HBM_SOUND_RETURN_APP
Definition hbm.h:36
@ HBM_SOUND_VOLUME_PLUS
Definition hbm.h:44
@ HBM_SOUND_VIBE_ON
Definition hbm.h:49
@ HBM_SOUND_FOCUS
Definition hbm.h:39
@ HBM_SOUND_CONNECTED3
Definition hbm.h:54
@ HBM_SOUND_END_CONNECT_WINDOW
Definition hbm.h:56
@ HBM_SOUND_CANCEL
Definition hbm.h:41
@ HBM_SOUND_MANUAL_OPEN
Definition hbm.h:57
@ HBM_SOUND_GOTO_MENU
Definition hbm.h:37
@ HBM_SOUND_MANUAL_SCROLL
Definition hbm.h:60
void HBMCreate(const HBMDataInfo *pHBInfo)
Definition HBMBase.cpp:45
HBMSelectBtnNum HBMGetSelectBtnNum(void)
Definition HBMBase.cpp:73
HBMSoundEvent_et
Definition hbm.h:25
@ HBM_SOUND_EVENT_0
Definition hbm.h:26
@ HBM_SOUND_EVENT_2
Definition hbm.h:28
@ HBM_SOUND_EVENT_PLAY
Definition hbm.h:31
@ HBM_SOUND_EVENT_3
Definition hbm.h:29
@ HBM_SOUND_EVENT_4
Definition hbm.h:30
@ HBM_SOUND_EVENT_1
Definition hbm.h:27
HBMSelectBtnNum HBMCalc(const HBMControllerData *pController)
Definition HBMBase.cpp:64
struct HBMDataInfo HBMDataInfo
void HBMDraw(void)
Definition HBMBase.cpp:69
void HBMCreateSound(void *soundData, void *memBuf, u32 memSize)
int HBMSoundCallback(int evt, int num)
Definition hbm.h:65
BOOL HBMIsReassignedControllers(void)
struct HBMKPadData HBMKPadData
void HBMDeleteSound(void)
Definition HBMBase.cpp:106
HBMSelectBtnNum
Definition hbm.h:13
@ HBM_SELECT_BTN2
Definition hbm.h:18
@ HBM_SELECT_BTN1
Definition hbm.h:17
@ HBM_SELECT_NULL
Definition hbm.h:14
@ HBM_SELECT_MAX
Definition hbm.h:22
@ HBM_SELECT_BTN3
Definition hbm.h:19
@ HBM_SELECT_BTN4
Definition hbm.h:20
@ HBM_SELECT_HOMEBTN
Definition hbm.h:16
int BOOL
Definition types.h:33
unsigned long u32
Definition types.h:12
float f32
Definition types.h:25
Definition hbm.h:88
HBMKPadData wiiCon[WPAD_MAX_CONTROLLERS]
Definition hbm.h:89
Definition hbm.h:66
void * spkSeBuf
Definition hbm.h:68
int region
Definition hbm.h:74
f32 frameDelta
Definition hbm.h:77
void * configBuf
Definition hbm.h:70
void * msgBuf
Definition hbm.h:69
void * layoutBuf
Definition hbm.h:67
u32 memSize
Definition hbm.h:76
int backFlag
Definition hbm.h:73
MEMAllocator * pAllocator
Definition hbm.h:79
HBMSoundCallback * sound_callback
Definition hbm.h:72
int cursor
Definition hbm.h:75
Vec2 adjust
Definition hbm.h:78
void * mem
Definition hbm.h:71
Definition hbm.h:82
KPADStatus * kpad
Definition hbm.h:83
Vec2 pos
Definition hbm.h:84
u32 use_devtype
Definition hbm.h:85
Definition kpad.h:57
Definition allocator.h:21
Definition kpad.h:30