Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
KODI::JOYSTICK Namespace Reference

Classes

struct  AxisConfiguration
 
class  CAccelerometer
 
class  CAnalogStick
 
class  CAxisDetector
 Detects when an axis should be mapped. More...
 
class  CAxisFeature
 
class  CButtonDetector
 Detects when a button should be mapped. More...
 
class  CButtonMapping
 Generic implementation of a class that provides button mapping by translating driver events to button mapping commands. More...
 
class  CDeadzoneFilter
 Analog axis deadzone filtering. More...
 
class  CDriverPrimitive
 Basic driver element associated with input events. More...
 
class  CDriverReceiving
 Class to translate input events from higher-level features to driver primitives. More...
 
class  CFeatureAxis
 Axis of a feature (analog stick, accelerometer, etc) More...
 
class  CGUIDialogNewJoystick
 
class  CHatDetector
 Detects when a D-pad direction should be mapped. More...
 
class  CInputHandling
 Class to translate input from the driver into higher-level features. More...
 
class  CJoystickEasterEgg
 Hush!!! More...
 
class  CJoystickFeature
 Base class for joystick features. More...
 
class  CJoystickMonitor
 Monitors joystick input and resets screensaver/shutdown timers whenever motion occurs. More...
 
class  CJoystickTranslator
 Joystick translation utilities. More...
 
class  CJoystickUtils
 
class  CKeyDetector
 Detects when a keyboard key should be mapped. More...
 
class  CMouseButtonDetector
 Detects when a mouse button should be mapped. More...
 
class  CPointerDetector
 Detects when a mouse button should be mapped. More...
 
class  CPrimitiveDetector
 Detects and dispatches mapping events. More...
 
class  CRumbleGenerator
 
class  CScalarFeature
 
class  CThrottle
 
class  CWheel
 
class  IButtonMap
 Button map interface to translate between the driver's raw button/hat/axis elements and physical joystick features. More...
 
class  IButtonMapCallback
 Interface for handling button maps. More...
 
class  IButtonMapper
 Button mapper interface to assign the driver's raw button/hat/axis elements to physical joystick features using a provided button map. More...
 
class  IButtonSequence
 
class  IDriverHandler
 Interface defining methods to handle joystick events for raw driver elements (buttons, hats, axes) More...
 
class  IDriverReceiver
 Interface for sending input events to joystick drivers. More...
 
class  IInputHandler
 Interface for handling input events for game controllers. More...
 
class  IInputProvider
 Interface for classes that can provide input. More...
 
class  IInputReceiver
 Interface for sending input events to game controllers. More...
 

Typedefs

using FeaturePtr = std::shared_ptr<CJoystickFeature>
 
using FeatureName = std::string
 Name of a physical feature belonging to the joystick.
 
using HAT_DIRECTION = INPUT::CARDINAL_DIRECTION
 Direction arrows on the hat (directional pad)
 
using HAT_STATE = INPUT::INTERCARDINAL_DIRECTION
 States in which a hat can be.
 
using ANALOG_STICK_DIRECTION = INPUT::CARDINAL_DIRECTION
 Typedef for analog stick directions.
 
using RELATIVE_POINTER_DIRECTION = INPUT::CARDINAL_DIRECTION
 Directions of motion for a relative pointer.
 

Enumerations

enum class  FEATURE_TYPE {
  UNKNOWN , SCALAR , ANALOG_STICK , ACCELEROMETER ,
  MOTOR , RELPOINTER , ABSPOINTER , WHEEL ,
  THROTTLE , KEY
}
 Types of features used in the joystick library. More...
 
enum class  FEATURE_CATEGORY {
  UNKNOWN , FACE , SHOULDER , TRIGGER ,
  ANALOG_STICK , ACCELEROMETER , HAPTICS , MOUSE_BUTTON ,
  POINTER , LIGHTGUN , OFFSCREEN , KEY ,
  KEYPAD , HARDWARE , WHEEL , JOYSTICK ,
  PADDLE
}
 Categories of features used in the joystick library. More...
 
enum class  SEMIAXIS_DIRECTION { NEGATIVE = -1 , ZERO = 0 , POSITIVE = 1 }
 Directions in which a semiaxis can point. More...
 
enum class  WHEEL_DIRECTION { NONE , RIGHT , LEFT }
 Directions on a wheel. More...
 
enum class  THROTTLE_DIRECTION { NONE , UP , DOWN }
 Directions on a throttle. More...
 
enum class  INPUT_TYPE { UNKNOWN , DIGITAL , ANALOG }
 Types of input available for scalar features. More...
 
enum class  PRIMITIVE_TYPE {
  UNKNOWN = 0 , BUTTON , HAT , SEMIAXIS ,
  MOTOR , KEY , MOUSE_BUTTON , RELATIVE_POINTER
}
 Type of driver primitive. More...
 

Functions

HAT_DIRECTIONoperator|= (HAT_DIRECTION &lhs, HAT_DIRECTION rhs)
 
HAT_STATEoperator|= (HAT_STATE &lhs, HAT_STATE rhs)
 
bool operator& (HAT_STATE lhs, HAT_DIRECTION rhs)
 
SEMIAXIS_DIRECTION operator* (SEMIAXIS_DIRECTION lhs, int rhs)
 
float operator* (float lhs, SEMIAXIS_DIRECTION rhs)
 

Typedef Documentation

◆ ANALOG_STICK_DIRECTION

Typedef for analog stick directions.

◆ FeatureName

using KODI::JOYSTICK::FeatureName = std::string

Name of a physical feature belonging to the joystick.

◆ FeaturePtr

using KODI::JOYSTICK::FeaturePtr = std::shared_ptr<CJoystickFeature>

◆ HAT_DIRECTION

Direction arrows on the hat (directional pad)

◆ HAT_STATE

States in which a hat can be.

◆ RELATIVE_POINTER_DIRECTION

Directions of motion for a relative pointer.

Enumeration Type Documentation

◆ FEATURE_CATEGORY

Categories of features used in the joystick library.

Enumerator
UNKNOWN 
FACE 
SHOULDER 
TRIGGER 
ANALOG_STICK 
ACCELEROMETER 
HAPTICS 
MOUSE_BUTTON 
POINTER 
LIGHTGUN 
OFFSCREEN 
KEY 
KEYPAD 
HARDWARE 
WHEEL 
JOYSTICK 
PADDLE 

◆ FEATURE_TYPE

enum class KODI::JOYSTICK::FEATURE_TYPE
strong

Types of features used in the joystick library.

Available types:

1) scalar[*] 2) analog stick 3) accelerometer 4) rumble motor 5) relative pointer 6) absolute pointer 7) wheel 8) throttle 9) keyboard key

[*] All three driver primitives (buttons, hats and axes) have a state that can be represented using a single scalar value. For this reason, features that map to a single primitive are called "scalar features".

Enumerator
UNKNOWN 
SCALAR 
ANALOG_STICK 
ACCELEROMETER 
MOTOR 
RELPOINTER 
ABSPOINTER 
WHEEL 
THROTTLE 
KEY 

◆ INPUT_TYPE

enum class KODI::JOYSTICK::INPUT_TYPE
strong

Types of input available for scalar features.

Enumerator
UNKNOWN 
DIGITAL 
ANALOG 

◆ PRIMITIVE_TYPE

enum class KODI::JOYSTICK::PRIMITIVE_TYPE
strong

Type of driver primitive.

Enumerator
UNKNOWN 
BUTTON 
HAT 
SEMIAXIS 
MOTOR 
KEY 
MOUSE_BUTTON 
RELATIVE_POINTER 

◆ SEMIAXIS_DIRECTION

Directions in which a semiaxis can point.

Enumerator
NEGATIVE 
ZERO 
POSITIVE 

◆ THROTTLE_DIRECTION

Directions on a throttle.

Enumerator
NONE 
UP 
DOWN 

◆ WHEEL_DIRECTION

Directions on a wheel.

Enumerator
NONE 
RIGHT 
LEFT 

Function Documentation

◆ operator&()

bool KODI::JOYSTICK::operator& ( HAT_STATE lhs,
HAT_DIRECTION rhs )
inline

◆ operator*() [1/2]

float KODI::JOYSTICK::operator* ( float lhs,
SEMIAXIS_DIRECTION rhs )
inline

◆ operator*() [2/2]

SEMIAXIS_DIRECTION KODI::JOYSTICK::operator* ( SEMIAXIS_DIRECTION lhs,
int rhs )
inline

◆ operator|=() [1/2]

HAT_DIRECTION & KODI::JOYSTICK::operator|= ( HAT_DIRECTION & lhs,
HAT_DIRECTION rhs )
inline

◆ operator|=() [2/2]

HAT_STATE & KODI::JOYSTICK::operator|= ( HAT_STATE & lhs,
HAT_STATE rhs )
inline