2008-09-12 07:28:40 +02:00
|
|
|
/****************************************************************************
|
2010-01-27 23:20:37 +01:00
|
|
|
* Snes9x Nintendo Wii/Gamecube Port
|
2008-09-12 07:28:40 +02:00
|
|
|
*
|
|
|
|
* softdev July 2006
|
|
|
|
* crunchy2 May-June 2007
|
2008-09-23 06:13:33 +02:00
|
|
|
* Michniewski 2008
|
2020-07-02 08:50:35 +02:00
|
|
|
* Tantric 2008-2020
|
2008-09-12 07:28:40 +02:00
|
|
|
*
|
|
|
|
* input.h
|
|
|
|
*
|
|
|
|
* Wii/Gamecube controller management
|
|
|
|
***************************************************************************/
|
2008-08-20 06:07:38 +02:00
|
|
|
|
|
|
|
#ifndef _INPUT_H_
|
|
|
|
#define _INPUT_H_
|
|
|
|
|
|
|
|
#include <gccore.h>
|
2009-03-16 06:16:20 +01:00
|
|
|
#include <wiiuse/wpad.h>
|
2018-09-06 03:59:14 +02:00
|
|
|
#include "utils/wiidrc.h"
|
2008-08-20 06:07:38 +02:00
|
|
|
|
|
|
|
#define PI 3.14159265f
|
|
|
|
#define PADCAL 50
|
2018-09-06 03:59:14 +02:00
|
|
|
#define WIIDRCCAL 20
|
2008-09-27 09:13:52 +02:00
|
|
|
#define MAXJP 12 // # of mappable controller buttons
|
2008-08-20 06:07:38 +02:00
|
|
|
|
2018-09-06 03:59:14 +02:00
|
|
|
extern u32 btnmap[4][6][12];
|
2009-04-13 10:43:50 +02:00
|
|
|
extern int rumbleRequest[4];
|
2020-09-29 00:46:30 +02:00
|
|
|
extern int playerMapping[4];
|
2008-08-20 06:07:38 +02:00
|
|
|
|
2009-07-01 19:15:47 +02:00
|
|
|
void ResetControls(int cc = -1, int wc = -1);
|
2009-03-11 18:28:37 +01:00
|
|
|
void ShutoffRumble();
|
|
|
|
void DoRumble(int i);
|
2010-04-01 23:34:35 +02:00
|
|
|
void ReportButtons ();
|
2008-08-20 06:07:38 +02:00
|
|
|
void SetControllers ();
|
|
|
|
void SetDefaultButtonMap ();
|
2009-05-28 06:16:41 +02:00
|
|
|
bool MenuRequested();
|
2009-10-13 02:48:00 +02:00
|
|
|
void SetupPads();
|
2009-06-27 22:03:15 +02:00
|
|
|
void UpdatePads();
|
2020-01-04 04:13:51 +01:00
|
|
|
#ifdef HW_RVL
|
2019-12-30 20:45:20 +01:00
|
|
|
char* GetUSBControllerInfo();
|
2020-01-04 04:13:51 +01:00
|
|
|
#endif
|
2008-08-20 06:07:38 +02:00
|
|
|
|
|
|
|
#endif
|