Skip to content

Commit

Permalink
Add SDL_SensorType definition
Browse files Browse the repository at this point in the history
  • Loading branch information
clementgallet committed Oct 25, 2022
1 parent 9e8b7f3 commit 8142563
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/library/inputs/sdlgamecontroller.h
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,14 @@ OVERRIDE Sint16 SDL_GameControllerGetAxis(SDL_GameController *gamecontroller,
OVERRIDE Uint8 SDL_GameControllerGetButton(SDL_GameController *gamecontroller,
SDL_GameControllerButton button);

typedef enum
{
SDL_SENSOR_INVALID = -1, /**< Returned for an invalid sensor */
SDL_SENSOR_UNKNOWN, /**< Unknown sensor type */
SDL_SENSOR_ACCEL, /**< Accelerometer */
SDL_SENSOR_GYRO /**< Gyroscope */
} SDL_SensorType;

/**
* Return whether a game controller has a particular sensor.
*
Expand Down

0 comments on commit 8142563

Please sign in to comment.