From ff4d794ca262ba0b383a7cdfaf95f5cfe29faeb0 Mon Sep 17 00:00:00 2001 From: "SND\\edgbla_cp" Date: Sun, 17 Apr 2011 19:19:31 +0000 Subject: Patch 9013 (Edomato). git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@65925 e17a0e51-4ae3-4d35-97c3-1a29b211df97 --- plugins/dfinput/pad.h | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) (limited to 'plugins/dfinput/pad.h') diff --git a/plugins/dfinput/pad.h b/plugins/dfinput/pad.h index 7c1b0e64..1ad35a43 100644 --- a/plugins/dfinput/pad.h +++ b/plugins/dfinput/pad.h @@ -36,6 +36,9 @@ extern "C" { #include #include +#if SDL_VERSION_ATLEAST(1,3,0) +#include +#endif #ifdef _MACOSX #include @@ -59,6 +62,11 @@ typedef void *Display; #define _(x) (x) #define N_(x) (x) #endif + +#if SDL_VERSION_ATLEAST(1,3,0) +int has_haptic; +#endif +int JoyHapticRumble(int pad, uint32_t low, uint32_t high); enum { DKEY_SELECT = 0, @@ -128,6 +136,16 @@ typedef struct tagPadState { volatile uint8_t AnalogKeyStatus[ANALOG_TOTAL][4]; uint8_t Vib0, Vib1; volatile uint8_t VibF[2]; +#if SDL_VERSION_ATLEAST(1,3,0) + SDL_Haptic *haptic; +#else +#ifdef __linux__ + int VibrateDev; + int VibrateEffect; + uint8_t VibrLow, VibrHigh; + uint32_t VibrSetTime; +#endif +#endif } PADSTATE; typedef struct tagGlobalData { -- cgit v1.2.3