rwops: Fixed some SDL2 symbols that got missed.
parent
5f64cc511e
commit
3a344cf877
|
@ -1051,7 +1051,7 @@ typedef SDL_GameController, SDL_Gamepad;
|
||||||
@@
|
@@
|
||||||
@@
|
@@
|
||||||
- SDL_GameControllerAddMappingsFromRW
|
- SDL_GameControllerAddMappingsFromRW
|
||||||
+ SDL_AddGamepadMappingsFromRW
|
+ SDL_AddGamepadMappingsFromIO
|
||||||
(...)
|
(...)
|
||||||
@@
|
@@
|
||||||
typedef SDL_GameControllerAxis, SDL_GamepadAxis;
|
typedef SDL_GameControllerAxis, SDL_GamepadAxis;
|
||||||
|
|
|
@ -526,7 +526,7 @@ The following structures have been renamed:
|
||||||
The following functions have been renamed:
|
The following functions have been renamed:
|
||||||
* SDL_GameControllerAddMapping() => SDL_AddGamepadMapping()
|
* SDL_GameControllerAddMapping() => SDL_AddGamepadMapping()
|
||||||
* SDL_GameControllerAddMappingsFromFile() => SDL_AddGamepadMappingsFromFile()
|
* SDL_GameControllerAddMappingsFromFile() => SDL_AddGamepadMappingsFromFile()
|
||||||
* SDL_GameControllerAddMappingsFromRW() => SDL_AddGamepadMappingsFromRW()
|
* SDL_GameControllerAddMappingsFromRW() => SDL_AddGamepadMappingsFromIO()
|
||||||
* SDL_GameControllerClose() => SDL_CloseGamepad()
|
* SDL_GameControllerClose() => SDL_CloseGamepad()
|
||||||
* SDL_GameControllerFromInstanceID() => SDL_GetGamepadFromInstanceID()
|
* SDL_GameControllerFromInstanceID() => SDL_GetGamepadFromInstanceID()
|
||||||
* SDL_GameControllerFromPlayerIndex() => SDL_GetGamepadFromPlayerIndex()
|
* SDL_GameControllerFromPlayerIndex() => SDL_GetGamepadFromPlayerIndex()
|
||||||
|
|
|
@ -279,7 +279,7 @@ extern DECLSPEC int SDLCALL SDL_AddGamepadMapping(const char *mapping);
|
||||||
* \sa SDL_AddGamepadMappingsFromFile
|
* \sa SDL_AddGamepadMappingsFromFile
|
||||||
* \sa SDL_GetGamepadMappingForGUID
|
* \sa SDL_GetGamepadMappingForGUID
|
||||||
*/
|
*/
|
||||||
extern DECLSPEC int SDLCALL SDL_AddGamepadMappingsFromRW(SDL_IOStream *src, SDL_bool freesrc);
|
extern DECLSPEC int SDLCALL SDL_AddGamepadMappingsFromIO(SDL_IOStream *src, SDL_bool freesrc);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Load a set of gamepad mappings from a file.
|
* Load a set of gamepad mappings from a file.
|
||||||
|
@ -301,7 +301,7 @@ extern DECLSPEC int SDLCALL SDL_AddGamepadMappingsFromRW(SDL_IOStream *src, SDL_
|
||||||
* \since This function is available since SDL 3.0.0.
|
* \since This function is available since SDL 3.0.0.
|
||||||
*
|
*
|
||||||
* \sa SDL_AddGamepadMapping
|
* \sa SDL_AddGamepadMapping
|
||||||
* \sa SDL_AddGamepadMappingsFromRW
|
* \sa SDL_AddGamepadMappingsFromIO
|
||||||
* \sa SDL_GetGamepadMappingForGUID
|
* \sa SDL_GetGamepadMappingForGUID
|
||||||
*/
|
*/
|
||||||
extern DECLSPEC int SDLCALL SDL_AddGamepadMappingsFromFile(const char *file);
|
extern DECLSPEC int SDLCALL SDL_AddGamepadMappingsFromFile(const char *file);
|
||||||
|
|
|
@ -205,7 +205,7 @@
|
||||||
#define SDL_GameController SDL_Gamepad
|
#define SDL_GameController SDL_Gamepad
|
||||||
#define SDL_GameControllerAddMapping SDL_AddGamepadMapping
|
#define SDL_GameControllerAddMapping SDL_AddGamepadMapping
|
||||||
#define SDL_GameControllerAddMappingsFromFile SDL_AddGamepadMappingsFromFile
|
#define SDL_GameControllerAddMappingsFromFile SDL_AddGamepadMappingsFromFile
|
||||||
#define SDL_GameControllerAddMappingsFromRW SDL_AddGamepadMappingsFromRW
|
#define SDL_GameControllerAddMappingsFromRW SDL_AddGamepadMappingsFromIO
|
||||||
#define SDL_GameControllerAxis SDL_GamepadAxis
|
#define SDL_GameControllerAxis SDL_GamepadAxis
|
||||||
#define SDL_GameControllerBindType SDL_GamepadBindingType
|
#define SDL_GameControllerBindType SDL_GamepadBindingType
|
||||||
#define SDL_GameControllerButton SDL_GamepadButton
|
#define SDL_GameControllerButton SDL_GamepadButton
|
||||||
|
@ -701,7 +701,7 @@
|
||||||
#define SDL_GameController SDL_GameController_renamed_SDL_Gamepad
|
#define SDL_GameController SDL_GameController_renamed_SDL_Gamepad
|
||||||
#define SDL_GameControllerAddMapping SDL_GameControllerAddMapping_renamed_SDL_AddGamepadMapping
|
#define SDL_GameControllerAddMapping SDL_GameControllerAddMapping_renamed_SDL_AddGamepadMapping
|
||||||
#define SDL_GameControllerAddMappingsFromFile SDL_GameControllerAddMappingsFromFile_renamed_SDL_AddGamepadMappingsFromFile
|
#define SDL_GameControllerAddMappingsFromFile SDL_GameControllerAddMappingsFromFile_renamed_SDL_AddGamepadMappingsFromFile
|
||||||
#define SDL_GameControllerAddMappingsFromRW SDL_GameControllerAddMappingsFromRW_renamed_SDL_AddGamepadMappingsFromRW
|
#define SDL_GameControllerAddMappingsFromRW SDL_GameControllerAddMappingsFromRW_renamed_SDL_AddGamepadMappingsFromIO
|
||||||
#define SDL_GameControllerAxis SDL_GameControllerAxis_renamed_SDL_GamepadAxis
|
#define SDL_GameControllerAxis SDL_GameControllerAxis_renamed_SDL_GamepadAxis
|
||||||
#define SDL_GameControllerBindType SDL_GameControllerBindType_renamed_SDL_GamepadBindingType
|
#define SDL_GameControllerBindType SDL_GameControllerBindType_renamed_SDL_GamepadBindingType
|
||||||
#define SDL_GameControllerButton SDL_GameControllerButton_renamed_SDL_GamepadButton
|
#define SDL_GameControllerButton SDL_GameControllerButton_renamed_SDL_GamepadButton
|
||||||
|
|
|
@ -548,7 +548,7 @@ extern DECLSPEC size_t SDLCALL SDL_IOvprintf(SDL_IOStream *context, SDL_PRINTF_F
|
||||||
*
|
*
|
||||||
* \since This function is available since SDL 3.0.0.
|
* \since This function is available since SDL 3.0.0.
|
||||||
*/
|
*/
|
||||||
extern DECLSPEC void *SDLCALL SDL_LoadFile_RW(SDL_IOStream *src, size_t *datasize, SDL_bool freesrc);
|
extern DECLSPEC void *SDLCALL SDL_LoadFile_IO(SDL_IOStream *src, size_t *datasize, SDL_bool freesrc);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Load all the data from a file path.
|
* Load all the data from a file path.
|
||||||
|
|
|
@ -4,7 +4,7 @@ SDL3_0.0.0 {
|
||||||
SDL_DYNAPI_entry;
|
SDL_DYNAPI_entry;
|
||||||
SDL_AddEventWatch;
|
SDL_AddEventWatch;
|
||||||
SDL_AddGamepadMapping;
|
SDL_AddGamepadMapping;
|
||||||
SDL_AddGamepadMappingsFromRW;
|
SDL_AddGamepadMappingsFromIO;
|
||||||
SDL_AddHintCallback;
|
SDL_AddHintCallback;
|
||||||
SDL_AddTimer;
|
SDL_AddTimer;
|
||||||
SDL_AndroidBackButton;
|
SDL_AndroidBackButton;
|
||||||
|
@ -409,7 +409,7 @@ SDL3_0.0.0 {
|
||||||
SDL_LoadBMP;
|
SDL_LoadBMP;
|
||||||
SDL_LoadBMP_IO;
|
SDL_LoadBMP_IO;
|
||||||
SDL_LoadFile;
|
SDL_LoadFile;
|
||||||
SDL_LoadFile_RW;
|
SDL_LoadFile_IO;
|
||||||
SDL_LoadFunction;
|
SDL_LoadFunction;
|
||||||
SDL_LoadObject;
|
SDL_LoadObject;
|
||||||
SDL_LockJoysticks;
|
SDL_LockJoysticks;
|
||||||
|
|
|
@ -28,7 +28,7 @@
|
||||||
|
|
||||||
#define SDL_AddEventWatch SDL_AddEventWatch_REAL
|
#define SDL_AddEventWatch SDL_AddEventWatch_REAL
|
||||||
#define SDL_AddGamepadMapping SDL_AddGamepadMapping_REAL
|
#define SDL_AddGamepadMapping SDL_AddGamepadMapping_REAL
|
||||||
#define SDL_AddGamepadMappingsFromRW SDL_AddGamepadMappingsFromRW_REAL
|
#define SDL_AddGamepadMappingsFromIO SDL_AddGamepadMappingsFromIO_REAL
|
||||||
#define SDL_AddHintCallback SDL_AddHintCallback_REAL
|
#define SDL_AddHintCallback SDL_AddHintCallback_REAL
|
||||||
#define SDL_AddTimer SDL_AddTimer_REAL
|
#define SDL_AddTimer SDL_AddTimer_REAL
|
||||||
#define SDL_AndroidBackButton SDL_AndroidBackButton_REAL
|
#define SDL_AndroidBackButton SDL_AndroidBackButton_REAL
|
||||||
|
@ -433,7 +433,7 @@
|
||||||
#define SDL_LoadBMP SDL_LoadBMP_REAL
|
#define SDL_LoadBMP SDL_LoadBMP_REAL
|
||||||
#define SDL_LoadBMP_IO SDL_LoadBMP_IO_REAL
|
#define SDL_LoadBMP_IO SDL_LoadBMP_IO_REAL
|
||||||
#define SDL_LoadFile SDL_LoadFile_REAL
|
#define SDL_LoadFile SDL_LoadFile_REAL
|
||||||
#define SDL_LoadFile_RW SDL_LoadFile_RW_REAL
|
#define SDL_LoadFile_IO SDL_LoadFile_IO_REAL
|
||||||
#define SDL_LoadFunction SDL_LoadFunction_REAL
|
#define SDL_LoadFunction SDL_LoadFunction_REAL
|
||||||
#define SDL_LoadObject SDL_LoadObject_REAL
|
#define SDL_LoadObject SDL_LoadObject_REAL
|
||||||
#define SDL_LockJoysticks SDL_LockJoysticks_REAL
|
#define SDL_LockJoysticks SDL_LockJoysticks_REAL
|
||||||
|
|
|
@ -103,7 +103,7 @@ SDL_DYNAPI_PROC(SDL_bool,SDL_IsDeXMode,(void),(),return)
|
||||||
|
|
||||||
SDL_DYNAPI_PROC(int,SDL_AddEventWatch,(SDL_EventFilter a, void *b),(a,b),return)
|
SDL_DYNAPI_PROC(int,SDL_AddEventWatch,(SDL_EventFilter a, void *b),(a,b),return)
|
||||||
SDL_DYNAPI_PROC(int,SDL_AddGamepadMapping,(const char *a),(a),return)
|
SDL_DYNAPI_PROC(int,SDL_AddGamepadMapping,(const char *a),(a),return)
|
||||||
SDL_DYNAPI_PROC(int,SDL_AddGamepadMappingsFromRW,(SDL_IOStream *a, SDL_bool b),(a,b),return)
|
SDL_DYNAPI_PROC(int,SDL_AddGamepadMappingsFromIO,(SDL_IOStream *a, SDL_bool b),(a,b),return)
|
||||||
SDL_DYNAPI_PROC(int,SDL_AddHintCallback,(const char *a, SDL_HintCallback b, void *c),(a,b,c),return)
|
SDL_DYNAPI_PROC(int,SDL_AddHintCallback,(const char *a, SDL_HintCallback b, void *c),(a,b,c),return)
|
||||||
SDL_DYNAPI_PROC(SDL_TimerID,SDL_AddTimer,(Uint32 a, SDL_TimerCallback b, void *c),(a,b,c),return)
|
SDL_DYNAPI_PROC(SDL_TimerID,SDL_AddTimer,(Uint32 a, SDL_TimerCallback b, void *c),(a,b,c),return)
|
||||||
SDL_DYNAPI_PROC(int,SDL_AtomicAdd,(SDL_AtomicInt *a, int b),(a,b),return)
|
SDL_DYNAPI_PROC(int,SDL_AtomicAdd,(SDL_AtomicInt *a, int b),(a,b),return)
|
||||||
|
@ -487,7 +487,7 @@ SDL_DYNAPI_PROC(SDL_bool,SDL_IsJoystickHaptic,(SDL_Joystick *a),(a),return)
|
||||||
SDL_DYNAPI_PROC(SDL_Surface*,SDL_LoadBMP,(const char *a),(a),return)
|
SDL_DYNAPI_PROC(SDL_Surface*,SDL_LoadBMP,(const char *a),(a),return)
|
||||||
SDL_DYNAPI_PROC(SDL_Surface*,SDL_LoadBMP_IO,(SDL_IOStream *a, SDL_bool b),(a,b),return)
|
SDL_DYNAPI_PROC(SDL_Surface*,SDL_LoadBMP_IO,(SDL_IOStream *a, SDL_bool b),(a,b),return)
|
||||||
SDL_DYNAPI_PROC(void*,SDL_LoadFile,(const char *a, size_t *b),(a,b),return)
|
SDL_DYNAPI_PROC(void*,SDL_LoadFile,(const char *a, size_t *b),(a,b),return)
|
||||||
SDL_DYNAPI_PROC(void*,SDL_LoadFile_RW,(SDL_IOStream *a, size_t *b, SDL_bool c),(a,b,c),return)
|
SDL_DYNAPI_PROC(void*,SDL_LoadFile_IO,(SDL_IOStream *a, size_t *b, SDL_bool c),(a,b,c),return)
|
||||||
SDL_DYNAPI_PROC(SDL_FunctionPointer,SDL_LoadFunction,(void *a, const char *b),(a,b),return)
|
SDL_DYNAPI_PROC(SDL_FunctionPointer,SDL_LoadFunction,(void *a, const char *b),(a,b),return)
|
||||||
SDL_DYNAPI_PROC(void*,SDL_LoadObject,(const char *a),(a),return)
|
SDL_DYNAPI_PROC(void*,SDL_LoadObject,(const char *a),(a),return)
|
||||||
SDL_DYNAPI_PROC(void,SDL_LockJoysticks,(void),(),)
|
SDL_DYNAPI_PROC(void,SDL_LockJoysticks,(void),(),)
|
||||||
|
|
|
@ -763,7 +763,7 @@ int SDL_CloseIO(SDL_IOStream *iostr)
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Load all the data from an SDL data stream */
|
/* Load all the data from an SDL data stream */
|
||||||
void *SDL_LoadFile_RW(SDL_IOStream *src, size_t *datasize, SDL_bool freesrc)
|
void *SDL_LoadFile_IO(SDL_IOStream *src, size_t *datasize, SDL_bool freesrc)
|
||||||
{
|
{
|
||||||
const int FILE_CHUNK_SIZE = 1024;
|
const int FILE_CHUNK_SIZE = 1024;
|
||||||
Sint64 size, size_total = 0;
|
Sint64 size, size_total = 0;
|
||||||
|
@ -832,7 +832,7 @@ done:
|
||||||
|
|
||||||
void *SDL_LoadFile(const char *file, size_t *datasize)
|
void *SDL_LoadFile(const char *file, size_t *datasize)
|
||||||
{
|
{
|
||||||
return SDL_LoadFile_RW(SDL_IOFromFile(file, "rb"), datasize, SDL_TRUE);
|
return SDL_LoadFile_IO(SDL_IOFromFile(file, "rb"), datasize, SDL_TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
SDL_PropertiesID SDL_GetRWProperties(SDL_IOStream *context)
|
SDL_PropertiesID SDL_GetRWProperties(SDL_IOStream *context)
|
||||||
|
|
|
@ -1789,7 +1789,7 @@ static GamepadMapping_t *SDL_PrivateGetGamepadMapping(SDL_JoystickID instance_id
|
||||||
/*
|
/*
|
||||||
* Add or update an entry into the Mappings Database
|
* Add or update an entry into the Mappings Database
|
||||||
*/
|
*/
|
||||||
int SDL_AddGamepadMappingsFromRW(SDL_IOStream *src, SDL_bool freesrc)
|
int SDL_AddGamepadMappingsFromIO(SDL_IOStream *src, SDL_bool freesrc)
|
||||||
{
|
{
|
||||||
const char *platform = SDL_GetPlatform();
|
const char *platform = SDL_GetPlatform();
|
||||||
int gamepads = 0;
|
int gamepads = 0;
|
||||||
|
@ -1797,7 +1797,7 @@ int SDL_AddGamepadMappingsFromRW(SDL_IOStream *src, SDL_bool freesrc)
|
||||||
size_t db_size;
|
size_t db_size;
|
||||||
size_t platform_len;
|
size_t platform_len;
|
||||||
|
|
||||||
buf = (char *)SDL_LoadFile_RW(src, &db_size, freesrc);
|
buf = (char *)SDL_LoadFile_IO(src, &db_size, freesrc);
|
||||||
if (!buf) {
|
if (!buf) {
|
||||||
return SDL_SetError("Could not allocate space to read DB into memory");
|
return SDL_SetError("Could not allocate space to read DB into memory");
|
||||||
}
|
}
|
||||||
|
@ -1845,7 +1845,7 @@ int SDL_AddGamepadMappingsFromRW(SDL_IOStream *src, SDL_bool freesrc)
|
||||||
|
|
||||||
int SDL_AddGamepadMappingsFromFile(const char *file)
|
int SDL_AddGamepadMappingsFromFile(const char *file)
|
||||||
{
|
{
|
||||||
return SDL_AddGamepadMappingsFromRW(SDL_IOFromFile(file, "rb"), 1);
|
return SDL_AddGamepadMappingsFromIO(SDL_IOFromFile(file, "rb"), 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
int SDL_ReloadGamepadMappings(void)
|
int SDL_ReloadGamepadMappings(void)
|
||||||
|
|
Loading…
Reference in New Issue