SDL
2.0
|
Go to the source code of this file.
void SDL_GameControllerHandleDelayedGuideButton | ( | SDL_Joystick * | joystick | ) |
Definition at line 2088 of file SDL_gamecontroller.c.
References SDL_GameController::joystick, SDL_CONTROLLER_BUTTON_GUIDE, SDL_gamecontrollers, SDL_PrivateGameControllerButton(), and SDL_RELEASED.
Referenced by SDL_JoystickUpdate().
int SDL_GameControllerInit | ( | void | ) |
Definition at line 1374 of file SDL_gamecontroller.c.
References SDL_Event::cdevice, i, NULL, SDL_AddEventWatch, SDL_CONTROLLERDEVICEADDED, SDL_GameControllerEventWatcher(), SDL_IsGameController(), SDL_NumJoysticks, SDL_PushEvent, SDL_Event::type, and SDL_ControllerDeviceEvent::which.
Referenced by SDL_InitSubSystem().
int SDL_GameControllerInitMappings | ( | void | ) |
Definition at line 1345 of file SDL_gamecontroller.c.
References i, NULL, s_ControllerMappings, SDL_AddHintCallback, SDL_CONTROLLER_MAPPING_PRIORITY_DEFAULT, SDL_GameControllerAddMappingsFromFile, SDL_GameControllerIgnoreDevicesChanged(), SDL_GameControllerIgnoreDevicesExceptChanged(), SDL_GameControllerLoadHints(), SDL_GetControllerMappingFilePath(), SDL_HINT_GAMECONTROLLER_IGNORE_DEVICES, SDL_HINT_GAMECONTROLLER_IGNORE_DEVICES_EXCEPT, and SDL_PrivateGameControllerAddMapping().
Referenced by SDL_JoystickInit().
Definition at line 1931 of file SDL_gamecontroller.c.
References SDL_GameControllerClose(), SDL_gamecontrollers, SDL_LockJoysticks, and SDL_UnlockJoysticks.
Referenced by SDL_QuitSubSystem().
Definition at line 1942 of file SDL_gamecontroller.c.
References SDL_vidpid_list::entries, NULL, s_pSupportedControllers, SDL_allowed_controllers, SDL_DelEventWatch, SDL_DelHintCallback, SDL_free, SDL_GameControllerEventWatcher(), SDL_GameControllerIgnoreDevicesChanged(), SDL_GameControllerIgnoreDevicesExceptChanged(), SDL_HINT_GAMECONTROLLER_IGNORE_DEVICES, SDL_HINT_GAMECONTROLLER_IGNORE_DEVICES_EXCEPT, SDL_ignored_controllers, and SDL_zero.
Referenced by SDL_JoystickQuit().
SDL_bool SDL_GetDriverAndJoystickIndex | ( | int | device_index, |
struct _SDL_JoystickDriver ** | driver, | ||
int * | driver_index | ||
) |
void SDL_GetJoystickGUIDInfo | ( | SDL_JoystickGUID | guid, |
Uint16 * | vendor, | ||
Uint16 * | product, | ||
Uint16 * | version | ||
) |
Definition at line 1125 of file SDL_joystick.c.
References SDL_JoystickGUID::data.
Referenced by SDL_GetJoystickGUIDType(), SDL_JoystickGetDeviceProduct(), SDL_JoystickGetDeviceProductVersion(), SDL_JoystickGetDeviceVendor(), SDL_JoystickGetProduct(), SDL_JoystickGetProductVersion(), SDL_JoystickGetVendor(), SDL_ShouldIgnoreGameController(), and SDL_ShouldIgnoreJoystick().
SDL_JoystickID SDL_GetNextJoystickInstanceID | ( | void | ) |
Definition at line 163 of file SDL_joystick.c.
References SDL_AtomicIncRef, and SDL_next_joystick_instance_id.
Referenced by IOS_AddJoystickDevice().
SDL_bool SDL_IsGameControllerNameAndGUID | ( | const char * | name, |
SDL_JoystickGUID | guid | ||
) |
Definition at line 1451 of file SDL_gamecontroller.c.
References SDL_FALSE, SDL_PrivateGetControllerMappingForNameAndGUID(), and SDL_TRUE.
Referenced by SDL_ShouldIgnoreJoystick().
SDL_bool SDL_IsJoystickHIDAPI | ( | SDL_JoystickGUID | guid | ) |
Definition at line 1208 of file SDL_joystick.c.
References SDL_JoystickGUID::data, SDL_FALSE, and SDL_TRUE.
Referenced by SDL_PrivateGetControllerMappingForGUID(), and SDL_PrivateGetControllerMappingForNameAndGUID().
Definition at line 1167 of file SDL_joystick.c.
References GuessControllerType(), k_eControllerType_SwitchInputOnlyController, and k_eControllerType_SwitchProController.
Definition at line 1161 of file SDL_joystick.c.
References GuessControllerType(), and k_eControllerType_PS4Controller.
Referenced by SDL_ShouldIgnoreJoystick().
Definition at line 1175 of file SDL_joystick.c.
References GuessControllerType(), k_eControllerType_SteamController, and k_eControllerType_SteamControllerV2.
Definition at line 1183 of file SDL_joystick.c.
References GuessControllerType(), k_eControllerType_XBox360Controller, and SDL_FALSE.
Definition at line 1196 of file SDL_joystick.c.
References GuessControllerType(), and k_eControllerType_XBoxOneController.
SDL_bool SDL_IsJoystickXInput | ( | SDL_JoystickGUID | guid | ) |
Definition at line 1202 of file SDL_joystick.c.
References SDL_JoystickGUID::data, SDL_FALSE, and SDL_TRUE.
Referenced by SDL_GetJoystickGUIDType(), and SDL_PrivateGetControllerMappingForGUID().
int SDL_JoystickGetDeviceIndexFromInstanceID | ( | SDL_JoystickID | instance_id | ) |
Definition at line 1560 of file SDL_joystick.c.
References i, SDL_JoystickGetDeviceInstanceID(), SDL_LockJoysticks(), SDL_NumJoysticks(), and SDL_UnlockJoysticks().
Referenced by SDL_PrivateJoystickAdded().
int SDL_JoystickInit | ( | void | ) |
Definition at line 114 of file SDL_joystick.c.
References i, NULL, SDL_AddHintCallback, SDL_arraysize, SDL_CreateMutex, SDL_GameControllerInitMappings(), SDL_HINT_JOYSTICK_ALLOW_BACKGROUND_EVENTS, SDL_INIT_EVENTS, SDL_InitSubSystem, SDL_joystick_drivers, SDL_joystick_lock, and SDL_JoystickAllowBackgroundEventsChanged().
Referenced by SDL_InitSubSystem().
Definition at line 697 of file SDL_joystick.c.
References i, mutex, NULL, SDL_arraysize, SDL_Delay, SDL_DelHintCallback, SDL_DestroyMutex, SDL_GameControllerQuitMappings(), SDL_HINT_JOYSTICK_ALLOW_BACKGROUND_EVENTS, SDL_INIT_EVENTS, SDL_joystick_drivers, SDL_joystick_lock, SDL_JoystickAllowBackgroundEventsChanged(), SDL_JoystickClose(), SDL_joysticks, SDL_LockJoysticks(), SDL_QuitSubSystem, SDL_UnlockJoysticks(), and SDL_updating_joystick.
Referenced by SDL_QuitSubSystem().
void SDL_PrivateJoystickAdded | ( | SDL_JoystickID | device_instance | ) |
Definition at line 755 of file SDL_joystick.c.
References SDL_ENABLE, SDL_GetEventState, SDL_JOYDEVICEADDED, SDL_JoystickGetDeviceIndexFromInstanceID(), and SDL_PushEvent.
Referenced by IOS_AddJoystickDevice().
Definition at line 833 of file SDL_joystick.c.
References axis, SDL_abs, SDL_ENABLE, SDL_GetEventState, SDL_JOYAXISMOTION, SDL_JOYSTICK_AXIS_MAX, SDL_PrivateJoystickAxis(), SDL_PrivateJoystickShouldIgnoreEvent(), SDL_PushEvent, and SDL_TRUE.
Referenced by IOS_AccelerometerUpdate(), IOS_MFIJoystickUpdate(), SDL_JoystickUpdate(), and SDL_PrivateJoystickAxis().
Definition at line 930 of file SDL_joystick.c.
References SDL_ENABLE, SDL_GetEventState, SDL_JOYBALLMOTION, SDL_PrivateJoystickShouldIgnoreEvent(), and SDL_PushEvent.
void SDL_PrivateJoystickBatteryLevel | ( | SDL_Joystick * | joystick, |
SDL_JoystickPowerLevel | ePowerLevel | ||
) |
Definition at line 1696 of file SDL_joystick.c.
Definition at line 966 of file SDL_joystick.c.
References button, SDL_ENABLE, SDL_GetEventState, SDL_JOYBUTTONDOWN, SDL_JOYBUTTONUP, SDL_PRESSED, SDL_PrivateJoystickShouldIgnoreEvent(), SDL_PushEvent, SDL_RELEASED, and state.
Referenced by IOS_MFIJoystickUpdate(), and SDL_JoystickUpdate().
Definition at line 890 of file SDL_joystick.c.
References SDL_ENABLE, SDL_GetEventState, SDL_HAT_CENTERED, SDL_JOYHATMOTION, SDL_PrivateJoystickShouldIgnoreEvent(), and SDL_PushEvent.
Referenced by IOS_MFIJoystickUpdate(), and SDL_JoystickUpdate().
void SDL_PrivateJoystickRemoved | ( | SDL_JoystickID | device_instance | ) |
Definition at line 805 of file SDL_joystick.c.
References SDL_ENABLE, SDL_FALSE, SDL_GetEventState, SDL_JOYDEVICEREMOVED, SDL_joysticks, SDL_PushEvent, SDL_TRUE, and UpdateEventsForDeviceRemoval().
Referenced by IOS_RemoveJoystickDevice().
int SDL_PrivateJoystickValid | ( | SDL_Joystick * | joystick | ) |
Definition at line 394 of file SDL_joystick.c.
References NULL, and SDL_SetError.
Referenced by SDL_HapticOpenFromJoystick(), SDL_JoystickClose(), SDL_JoystickCurrentPowerLevel(), SDL_JoystickGetAttached(), SDL_JoystickGetAxis(), SDL_JoystickGetAxisInitialState(), SDL_JoystickGetBall(), SDL_JoystickGetButton(), SDL_JoystickGetGUID(), SDL_JoystickGetHat(), SDL_JoystickGetPlayerIndex(), SDL_JoystickInstanceID(), SDL_JoystickIsHaptic(), SDL_JoystickName(), SDL_JoystickNumAxes(), SDL_JoystickNumBalls(), SDL_JoystickNumButtons(), SDL_JoystickNumHats(), and SDL_JoystickRumble().
SDL_bool SDL_ShouldIgnoreGameController | ( | const char * | name, |
SDL_JoystickGUID | guid | ||
) |
Definition at line 1476 of file SDL_gamecontroller.c.
References SDL_vidpid_list::entries, i, MAKE_VIDPID, SDL_vidpid_list::num_entries, SDL_allowed_controllers, SDL_FALSE, SDL_GetHintBoolean, SDL_GetJoystickGUIDInfo(), SDL_ignored_controllers, SDL_strstr, and SDL_TRUE.
Referenced by SDL_ShouldIgnoreJoystick().
SDL_bool SDL_ShouldIgnoreJoystick | ( | const char * | name, |
SDL_JoystickGUID | guid | ||
) |
Definition at line 1359 of file SDL_joystick.c.
References i, MAKE_VIDPID, NULL, SDL_arraysize, SDL_FALSE, SDL_GetJoystickGUIDInfo(), SDL_IsGameControllerNameAndGUID(), SDL_IsJoystickPS4(), SDL_IsPS4RemapperRunning(), SDL_ShouldIgnoreGameController(), and SDL_TRUE.