Build hidapi code into SDL as a new public API

This prevents conflicts with hidapi linked with applications, as well as allowing applications to make use of HIDAPI on Android and other platforms that might not normally have an implementation available.
This commit is contained in:
Sam Lantinga
2021-11-07 22:58:44 -08:00
parent 94c1276a5f
commit 5b646cd19e
35 changed files with 798 additions and 633 deletions

View File

@@ -827,3 +827,18 @@
#define SDL_LinuxSetThreadPriorityAndPolicy SDL_LinuxSetThreadPriorityAndPolicy_REAL
#define SDL_GameControllerGetAppleSFSymbolsNameForButton SDL_GameControllerGetAppleSFSymbolsNameForButton_REAL
#define SDL_GameControllerGetAppleSFSymbolsNameForAxis SDL_GameControllerGetAppleSFSymbolsNameForAxis_REAL
#define SDL_hid_init SDL_hid_init_REAL
#define SDL_hid_exit SDL_hid_exit_REAL
#define SDL_hid_enumerate SDL_hid_enumerate_REAL
#define SDL_hid_free_enumeration SDL_hid_free_enumeration_REAL
#define SDL_hid_write SDL_hid_write_REAL
#define SDL_hid_read_timeout SDL_hid_read_timeout_REAL
#define SDL_hid_read SDL_hid_read_REAL
#define SDL_hid_set_nonblocking SDL_hid_set_nonblocking_REAL
#define SDL_hid_send_feature_report SDL_hid_send_feature_report_REAL
#define SDL_hid_get_feature_report SDL_hid_get_feature_report_REAL
#define SDL_hid_close SDL_hid_close_REAL
#define SDL_hid_get_manufacturer_string SDL_hid_get_manufacturer_string_REAL
#define SDL_hid_get_product_string SDL_hid_get_product_string_REAL
#define SDL_hid_get_serial_number_string SDL_hid_get_serial_number_string_REAL
#define SDL_hid_get_indexed_string SDL_hid_get_indexed_string_REAL