LRT13
1.0
Main Page
Namespaces
Classes
Files
File List
All
Classes
Namespaces
Functions
Variables
Enumerations
Enumerator
Operations
DebouncedJoystick.h
1
#ifndef DEBOUNCED_JOYSTICK_H_
2
#define DEBOUNCED_JOYSTICK_H_
3
4
#include "Joystick.h"
5
6
class
DebouncedJoystick:
public
Joystick
7
{
8
public
:
9
DebouncedJoystick(UINT32 port,
int
nBtns,
int
nAxes);
10
~DebouncedJoystick();
11
12
void
Init();
13
void
Update();
14
15
bool
ButtonInBounds(
int
button);
16
bool
AxisInBounds(
int
axis);
17
18
bool
IsButtonJustPressed(
int
button);
19
bool
IsButtonJustReleased(
int
button);
20
bool
IsButtonDown(
int
button);
21
bool
WasButtonDown(
int
button);
22
23
bool
IsHatSwitchJustPressed(
int
axis,
int
direction);
24
bool
IsHatSwitchJustReleased(
int
axis,
int
direction);
25
bool
IsHatSwitchDown(
int
axis,
int
direction);
26
bool
WasHatSwitchDown(
int
axis,
int
direction);
27
28
double
GetRawAxisDelta(
int
axis);
29
30
private
:
31
int
m_num_buttons, m_num_axes;
32
bool
* wasPressed;
33
bool
* isPressed;
34
double
* axisPrevValue;
35
double
* axisValue;
36
};
37
38
#endif
Generated on Thu Nov 28 2013 20:16:51 for LRT13 by
1.8.3