RetroArch
kpad.h
Go to the documentation of this file.
1 #pragma once
2 
3 #ifdef __cplusplus
4 extern "C" {
5 #endif
6 
7 #include <wiiu/types.h>
8 #include <wiiu/wpad.h>
9 
10 typedef struct _KPADData
11 {
26 
27  union
28  {
29  struct
30  {
33  } nunchuck;
34 
35  struct
36  {
37  u32 btns_h;
38  u32 btns_d;
39  u32 btns_r;
46  } classic;
47 
48  struct
49  {
53  f32 lstick_x;
54  f32 lstick_y;
55  f32 rstick_x;
56  f32 rstick_y;
59  } pro;
60 
62  };
64 } KPADData;
65 
66 
67 void KPADInit (void);
68 void KPADShutdown(void);
69 s32 KPADRead(s32 chan, void * data, u32 size);
71 
72 typedef s32 WPADChannel;
73 /* legal values for WPADChannel */
74 enum {
79 };
80 
81 typedef s8 WPADError;
82 /* legal values for WPADError */
83 enum {
92 };
93 
95 
96 
97 #ifdef __cplusplus
98 }
99 #endif
Definition: kpad.h:78
s32 WPADChannel
Definition: kpad.h:72
struct _KPADData KPADData
f32 stick_x
Definition: kpad.h:31
u8 pos_valid
Definition: kpad.h:24
int32_t s32
32bit signed integer
Definition: gctypes.h:24
struct _KPADData::@920::@922 nunchuck
u8 device_type
Definition: kpad.h:22
Definition: kpad.h:88
u32 btns_h
Definition: kpad.h:12
Definition: kpad.h:89
float f32
Definition: gctypes.h:43
Definition: kpad.h:84
f32 rstick_y
Definition: kpad.h:43
int8_t s8
8bit signed integer
Definition: gctypes.h:22
GLsizeiptr size
Definition: glext.h:6559
u32 unused_1[5]
Definition: kpad.h:15
s32 KPADReadEx(s32 chan, KPADData *data, u32 size, s32 *error)
s32 KPADRead(s32 chan, void *data, u32 size)
typedef void(__stdcall *PFN_DESTRUCTION_CALLBACK)(void *pData)
Definition: kpad.h:85
Definition: ibxm.h:9
s8 WPADError
Definition: kpad.h:81
f32 lstick_x
Definition: kpad.h:40
struct _KPADData::@920::@924 pro
Definition: kpad.h:87
void KPADInit(void)
f32 angle_x
Definition: kpad.h:19
Definition: kpad.h:10
u32 btns_d
Definition: kpad.h:13
u8 format
Definition: kpad.h:25
f32 rstick_x
Definition: kpad.h:42
static l_noret error(LoadState *S, const char *why)
Definition: lundump.c:39
Definition: kpad.h:77
f32 pos_y
Definition: kpad.h:17
Definition: kpad.h:91
f32 lstick_y
Definition: kpad.h:41
u32 btns_r
Definition: kpad.h:14
f32 rtrigger
Definition: kpad.h:45
f32 pos_x
Definition: kpad.h:16
u32 unused_2[3]
Definition: kpad.h:18
Definition: kpad.h:90
u32 trigger
Definition: kpad.h:51
Definition: ibxm.c:40
s32 wired
Definition: kpad.h:58
Definition: kpad.h:76
Definition: kpad.h:86
f32 angle_y
Definition: kpad.h:20
u32 unused_6[20]
Definition: kpad.h:61
f32 stick_y
Definition: kpad.h:32
u32 unused_7[16]
Definition: kpad.h:63
s32 charging
Definition: kpad.h:57
u32 unused_3[8]
Definition: kpad.h:21
Definition: kpad.h:75
void KPADShutdown(void)
f32 ltrigger
Definition: kpad.h:44
u32 hold
Definition: kpad.h:50
uint8_t u8
8bit unsigned integer
Definition: gctypes.h:17
uint32_t u32
32bit unsigned integer
Definition: gctypes.h:19
void(* WPADConnectCallback)(WPADChannel channel, WPADError reason)
Definition: kpad.h:94
struct _KPADData::@920::@923 classic
u8 wpad_error
Definition: kpad.h:23
u32 release
Definition: kpad.h:52